|
@@ -0,0 +1,253 @@
|
|
|
+
|
|
|
+
|
|
|
+{
|
|
|
+
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+{
|
|
|
+ const flover = {
|
|
|
+ type: 'palm',
|
|
|
+ height: 150,
|
|
|
+ color: 'green'
|
|
|
+ }
|
|
|
+
|
|
|
+ const dog = {
|
|
|
+ type: 'york',
|
|
|
+ sex: 'female',
|
|
|
+ color: 'red'
|
|
|
+ }
|
|
|
+
|
|
|
+ const wife = {
|
|
|
+ type: 'creator',
|
|
|
+ sex: 'female',
|
|
|
+ height: 165
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+{
|
|
|
+ const flover = {
|
|
|
+ type: 'palm',
|
|
|
+ height: 150,
|
|
|
+ color: 'green',
|
|
|
+ [prompt('Введите первый параметр для объекта "Цветок"')]: prompt('Введите описание этого параметра'),
|
|
|
+ [prompt('Введите второй параметр для объекта "Цветок"')]: prompt('Введите описание этого параметра')
|
|
|
+ }
|
|
|
+
|
|
|
+ const dog = {
|
|
|
+ type: 'york',
|
|
|
+ sex: 'female',
|
|
|
+ color: 'red',
|
|
|
+ [prompt('Введите первый параметр для объекта "Собака"')]: prompt('Введите описание этого параметра'),
|
|
|
+ [prompt('Введите второй параметр для объекта "Собака"')]: prompt('Введите описание этого параметра')
|
|
|
+ }
|
|
|
+
|
|
|
+ const wife = {
|
|
|
+ type: 'creator',
|
|
|
+ sex: 'female',
|
|
|
+ height: 165,
|
|
|
+ [prompt('Введите первый параметр для объекта "Жена"')]: prompt('Введите описание этого параметра'),
|
|
|
+ [prompt('Введите второй параметр для объекта "Жена"')]: prompt('Введите описание этого параметра')
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+{
|
|
|
+
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+{
|
|
|
+ const dataInput = {
|
|
|
+ tagName: 'body',
|
|
|
+ children: [
|
|
|
+ {
|
|
|
+ nameTag: 'div',
|
|
|
+ children: [
|
|
|
+ {
|
|
|
+ tagName: 'span',
|
|
|
+ children: ['Enter a data please:']
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'br'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'input',
|
|
|
+ attrs: {
|
|
|
+ type: 'text',
|
|
|
+ id: 'name'
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'input',
|
|
|
+ attrs: {
|
|
|
+ type: 'text',
|
|
|
+ id: 'surname'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ },
|
|
|
+ {
|
|
|
+ nameTag: 'div',
|
|
|
+ children: [
|
|
|
+ {
|
|
|
+ tagName: 'button',
|
|
|
+ attrs: {
|
|
|
+ id: 'ok'
|
|
|
+ },
|
|
|
+ children: ['OK']
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'button',
|
|
|
+ attrs: {
|
|
|
+ id: 'cancel'
|
|
|
+ },
|
|
|
+ children: ['Cancel']
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+{
|
|
|
+ const dataInput = {
|
|
|
+ tagName: 'body',
|
|
|
+ children: [
|
|
|
+ {
|
|
|
+ nameTag: 'div',
|
|
|
+ children: [
|
|
|
+ {
|
|
|
+ tagName: 'span',
|
|
|
+ children: ['Enter a data please:']
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'br'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'input',
|
|
|
+ attrs: {
|
|
|
+ type: 'text',
|
|
|
+ id: 'name'
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'input',
|
|
|
+ attrs: {
|
|
|
+ type: 'text',
|
|
|
+ id: 'surname'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ },
|
|
|
+ {
|
|
|
+ nameTag: 'div',
|
|
|
+ children: [
|
|
|
+ {
|
|
|
+ tagName: 'button',
|
|
|
+ attrs: {
|
|
|
+ id: 'ok'
|
|
|
+ },
|
|
|
+ children: ['OK']
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'button',
|
|
|
+ attrs: {
|
|
|
+ id: 'cancel'
|
|
|
+ },
|
|
|
+ children: ['Cancel']
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }
|
|
|
+ dataInput.children[0].father = dataInput
|
|
|
+ dataInput.children[1].father = dataInput
|
|
|
+ dataInput.children[1].father = dataInput
|
|
|
+ dataInput.children[0].children[0].father = dataInput.children[0]
|
|
|
+ dataInput.children[0].children[1].father = dataInput.children[0]
|
|
|
+ dataInput.children[0].children[2].father = dataInput.children[0]
|
|
|
+ dataInput.children[0].children[3].father = dataInput.children[0]
|
|
|
+ dataInput.children[1].children[0].father = dataInput.children[1]
|
|
|
+ dataInput.children[1].children[1].father = dataInput.children[1]
|
|
|
+}
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+{
|
|
|
+ const dataInput = {
|
|
|
+ tagName: 'body',
|
|
|
+ children: [
|
|
|
+ {
|
|
|
+ nameTag: 'div',
|
|
|
+ children: [
|
|
|
+ {
|
|
|
+ tagName: 'span',
|
|
|
+ children: ['Enter a data please:']
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'br'
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'input',
|
|
|
+ attrs: {
|
|
|
+ type: 'text',
|
|
|
+ id: 'name'
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'input',
|
|
|
+ attrs: {
|
|
|
+ type: 'text',
|
|
|
+ id: 'surname'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ },
|
|
|
+ {
|
|
|
+ nameTag: 'div',
|
|
|
+ children: [
|
|
|
+ {
|
|
|
+ tagName: 'button',
|
|
|
+ attrs: {
|
|
|
+ id: 'ok'
|
|
|
+ },
|
|
|
+ children: ['OK']
|
|
|
+ },
|
|
|
+ {
|
|
|
+ tagName: 'button',
|
|
|
+ attrs: {
|
|
|
+ id: 'cancel'
|
|
|
+ },
|
|
|
+ children: ['Cancel']
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }
|
|
|
+ ]
|
|
|
+ }
|
|
|
+}
|