aloha-vue 1.0.13 → 1.0.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (117) hide show
  1. package/docs/package.json +2 -1
  2. package/docs/src/App/App.js +2 -0
  3. package/docs/src/App/App.pug +2 -1
  4. package/docs/src/components/TheMenu/TheMenu.js +30 -0
  5. package/docs/src/router/index.js +30 -0
  6. package/docs/src/views/PageCheckbox/PageCheckbox.js +35 -0
  7. package/docs/src/views/PageCheckbox/PageCheckbox.pug +78 -0
  8. package/docs/src/views/PageCheckbox/PageCheckbox.vue +2 -0
  9. package/docs/src/views/PageConfirm/PageConfirm.js +0 -1
  10. package/docs/src/views/PageDropdown/PageDropdown.js +13 -0
  11. package/docs/src/views/PageDropdown/PageDropdown.pug +29 -0
  12. package/docs/src/views/PageDropdown/PageDropdown.vue +2 -0
  13. package/docs/src/views/PageForm/PageForm.js +200 -0
  14. package/docs/src/views/PageForm/PageForm.pug +31 -0
  15. package/docs/src/views/PageForm/PageForm.vue +2 -0
  16. package/docs/src/views/PageInput/PageInput.js +2 -1
  17. package/docs/src/views/PageInput/PageInput.pug +11 -0
  18. package/docs/src/views/PageNotification/PageNotification.js +34 -0
  19. package/docs/src/views/PageNotification/PageNotification.pug +9 -0
  20. package/docs/src/views/PageNotification/PageNotification.vue +2 -0
  21. package/docs/src/views/PageRadio/PageRadio.js +31 -0
  22. package/docs/src/views/PageRadio/PageRadio.pug +54 -0
  23. package/docs/src/views/PageRadio/PageRadio.vue +2 -0
  24. package/docs/src/views/PageSelect/PageSelect.js +59 -0
  25. package/docs/src/views/PageSelect/PageSelect.pug +53 -0
  26. package/docs/src/views/PageSelect/PageSelect.vue +2 -0
  27. package/docs/src/views/PageSpinner/PageSpinner.pug +6 -8
  28. package/docs/styles/styles.scss +0 -6
  29. package/package.json +2 -2
  30. package/src/ADropdown/ADropdown.js +126 -46
  31. package/src/AModal/AModal.js +75 -13
  32. package/src/ANotification/ANotification.js +46 -0
  33. package/src/ASlot/ASlot.js +3 -0
  34. package/src/ASpinner/ASpinner.js +10 -41
  35. package/src/ATable/ATableHeaderThAction/ATableHeaderThAction.js +5 -1
  36. package/src/ATable/ATableHeaderThAction/ATableHeaderThActionItem.js +5 -3
  37. package/src/ATable/ATableTdAction/ATableTdAction.js +6 -1
  38. package/src/compositionAPI/AEventOutsideAPI.js +46 -0
  39. package/src/compositionAPI/ANotificationAPI.js +51 -0
  40. package/src/const/AFocusableElements.js +13 -0
  41. package/src/const/AKeysCode.js +8 -0
  42. package/src/styles/components/ADropdown.scss +24 -19
  43. package/src/styles/components/ATable.scss +17 -7
  44. package/src/styles/components/ui/AErrors.scss +5 -0
  45. package/src/styles/components/ui/AFieldset.scss +27 -0
  46. package/src/styles/components/ui/AForm.scss +4 -0
  47. package/src/styles/components/ui/ASelect.scss +143 -0
  48. package/src/styles/components/ui/ASwitch.scss +39 -19
  49. package/src/styles/components/ui/ui.scss +27 -5
  50. package/src/ui/ACheckbox/ACheckbox.js +148 -0
  51. package/src/ui/ACheckbox/ACheckboxItem.js +129 -0
  52. package/src/ui/AErrors/AErrors.js +155 -0
  53. package/src/ui/AErrors/AErrorsElement.js +206 -0
  54. package/src/ui/AErrorsText/AErrorsText.js +47 -0
  55. package/src/ui/AFieldset/AFieldset.js +116 -0
  56. package/src/ui/AForm/AForm.js +131 -0
  57. package/src/ui/AInput/AInput.js +86 -79
  58. package/src/ui/ALabel/ALabel.js +31 -26
  59. package/src/ui/AOneCheckbox/AOneCheckbox.js +146 -0
  60. package/src/ui/ARadio/ARadio.js +153 -0
  61. package/src/ui/ARadio/ARadioItem.js +120 -0
  62. package/src/ui/ARequired/ARequired.js +20 -0
  63. package/src/ui/ASelect/ASelect.js +600 -0
  64. package/src/ui/ASelect/ASelectElement.js +151 -0
  65. package/src/ui/ASelect/ASelectGroup.js +120 -0
  66. package/src/ui/ASelect/ASelectLabelElement.js +37 -0
  67. package/src/ui/ASelect/ASelectValueCloseable.js +66 -0
  68. package/src/ui/ASelect/UiSelect/ReadOnlyMixin.js +120 -0
  69. package/src/ui/ASelect/UiSelect/UiMultiselectReadOnly/UiMultiselectReadOnly.js +62 -0
  70. package/src/ui/ASelect/UiSelect/UiMultiselectReadOnly/UiMultiselectReadOnly.pug +61 -0
  71. package/src/ui/ASelect/UiSelect/UiMultiselectReadOnly/UiMultiselectReadOnly.vue +2 -0
  72. package/src/ui/ASelect/UiSelect/UiMultiselectReadOnly/UiMultiselectReadOnlyElement/UiMultiselectReadOnlyElement.js +39 -0
  73. package/src/ui/ASelect/UiSelect/UiMultiselectReadOnly/UiMultiselectReadOnlyElement/UiMultiselectReadOnlyElement.pug +6 -0
  74. package/src/ui/ASelect/UiSelect/UiMultiselectReadOnly/UiMultiselectReadOnlyElement/UiMultiselectReadOnlyElement.vue +2 -0
  75. package/src/ui/ASelect/UiSelect/UiSelect.js +1119 -0
  76. package/src/ui/ASelect/UiSelect/UiSelect.pug +371 -0
  77. package/src/ui/ASelect/UiSelect/UiSelect.vue +2 -0
  78. package/src/ui/ASelect/UiSelect/UiSelectElement/UiSelectElement.js +174 -0
  79. package/src/ui/ASelect/UiSelect/UiSelectElement/UiSelectElement.vue +1 -0
  80. package/src/ui/ASelect/UiSelect/UiSelectOrdered/UiSelectOrdered.js +133 -0
  81. package/src/ui/ASelect/UiSelect/UiSelectOrdered/UiSelectOrdered.pug +47 -0
  82. package/src/ui/ASelect/UiSelect/UiSelectOrdered/UiSelectOrdered.vue +2 -0
  83. package/src/ui/ASelect/UiSelect/UiSelectOrdered/UiSelectOrderedElement/UiSelectOrderedElement.js +99 -0
  84. package/src/ui/ASelect/UiSelect/UiSelectOrdered/UiSelectOrderedElement/UiSelectOrderedElement.pug +38 -0
  85. package/src/ui/ASelect/UiSelect/UiSelectOrdered/UiSelectOrderedElement/UiSelectOrderedElement.vue +2 -0
  86. package/src/ui/ASelect/UiSelect/UiSelectReadOnly/UiSelectReadOnly.js +31 -0
  87. package/src/ui/ASelect/UiSelect/UiSelectReadOnly/UiSelectReadOnly.pug +21 -0
  88. package/src/ui/ASelect/UiSelect/UiSelectReadOnly/UiSelectReadOnly.vue +2 -0
  89. package/src/ui/ASelect/compositionAPI/ASelectDataAPI.js +66 -0
  90. package/src/ui/ASelect/compositionAPI/ASelectModelChangeAPI.js +98 -0
  91. package/src/ui/ASelect/compositionAPI/ASelectSearchAPI.js +80 -0
  92. package/src/ui/ASelect/compositionAPI/ASelectToggleAPI.js +221 -0
  93. package/src/ui/ASwitch/ASwitch.js +78 -91
  94. package/src/ui/ATemplate/ATemplate.js +47 -0
  95. package/src/ui/ATextarea/ATextarea.js +219 -0
  96. package/src/ui/AUiComponents.js +25 -0
  97. package/src/ui/compositionApi/UiAPI.js +53 -56
  98. package/src/ui/compositionApi/UiCheckboxRadioItem.js +31 -0
  99. package/src/ui/compositionApi/UiClearButtonAPI.js +1 -20
  100. package/src/ui/compositionApi/UiDataWithKeyIdAndLabelAPI.js +68 -0
  101. package/src/ui/compositionApi/UiDependenciesAPI.js +47 -0
  102. package/src/ui/compositionApi/UiErrorsAPI.js +37 -0
  103. package/src/ui/const/AKeyId.js +1 -0
  104. package/src/ui/const/AKeyLabel.js +1 -0
  105. package/src/ui/mixins/UiMixinProps.js +41 -6
  106. package/src/ADropdown/PuxDropdown/PuxDropdown.js +0 -239
  107. package/src/ADropdown/PuxDropdown/PuxDropdown.pug +0 -49
  108. package/src/ADropdown/PuxDropdown/PuxDropdown.vue +0 -2
  109. package/src/ADropdown/PuxPopover/PuxPopover.js +0 -197
  110. package/src/ADropdown/PuxPopover/PuxPopover.pug +0 -13
  111. package/src/ADropdown/PuxPopover/PuxPopover.vue +0 -2
  112. package/src/ADropdown/TooltipContent/TooltipContent.js +0 -109
  113. package/src/ADropdown/TooltipContent/TooltipContent.pug +0 -17
  114. package/src/ADropdown/TooltipContent/TooltipContent.vue +0 -2
  115. package/src/ATextarea/ATextarea.js +0 -256
  116. package/src/styles/components/ASpinner.scss +0 -24
  117. package/src/ui/compositionApi/UiLabelFloatAPI.js +0 -18
package/docs/package.json CHANGED
@@ -11,7 +11,8 @@
11
11
  "build-css": "node-sass --include-path scss styles/styles.scss public/styles.css"
12
12
  },
13
13
  "dependencies": {
14
- "aloha-css": "1.0.11",
14
+ "@popperjs/core": "2.11.6",
15
+ "aloha-css": "1.0.25",
15
16
  "lodash-es": "^4.17.21",
16
17
  "vue": "3.2.31",
17
18
  "vue-router": "4.0.14",
@@ -1,4 +1,5 @@
1
1
  import AModalConfirm from "../../../src/AModalConfirm/AModalConfirm";
2
+ import ANotification from "../../../src/ANotification/ANotification";
2
3
  import TheMenu from "../components/TheMenu/TheMenu.vue";
3
4
  import TheNavbar from "../components/TheNavbar/TheNavbar.vue";
4
5
 
@@ -10,6 +11,7 @@ import {
10
11
  export default defineComponent({
11
12
  components: {
12
13
  AModalConfirm,
14
+ ANotification,
13
15
  TheMenu,
14
16
  TheNavbar,
15
17
  },
@@ -9,4 +9,5 @@ div
9
9
  )
10
10
  router-view
11
11
 
12
- a-modal-confirm
12
+ a-modal-confirm
13
+ a-notification
@@ -58,6 +58,36 @@ export default {
58
58
  name: "PageConfirm",
59
59
  label: "Confirm",
60
60
  },
61
+ {
62
+ id: "notification",
63
+ name: "PageNotification",
64
+ label: "Notification",
65
+ },
66
+ {
67
+ id: "checkbox",
68
+ name: "PageCheckbox",
69
+ label: "Checkbox",
70
+ },
71
+ {
72
+ id: "radio",
73
+ name: "PageRadio",
74
+ label: "Radio",
75
+ },
76
+ {
77
+ id: "select",
78
+ name: "PageSelect",
79
+ label: "Select",
80
+ },
81
+ {
82
+ id: "form",
83
+ name: "PageForm",
84
+ label: "Form",
85
+ },
86
+ {
87
+ id: "dropdown",
88
+ name: "PageDropdown",
89
+ label: "Dropdown",
90
+ },
61
91
  ],
62
92
  };
63
93
  },
@@ -69,6 +69,36 @@ const ROUTES = [
69
69
  name: "PageConfirm",
70
70
  component: () => import(/* webpackChunkName: "PageConfirm" */ "../views/PageConfirm/PageConfirm.vue"),
71
71
  },
72
+ {
73
+ path: "/notification",
74
+ name: "PageNotification",
75
+ component: () => import(/* webpackChunkName: "PageNotification" */ "../views/PageNotification/PageNotification.vue"),
76
+ },
77
+ {
78
+ path: "/checkbox",
79
+ name: "PageCheckbox",
80
+ component: () => import(/* webpackChunkName: "PageCheckbox" */ "../views/PageCheckbox/PageCheckbox.vue"),
81
+ },
82
+ {
83
+ path: "/radio",
84
+ name: "PageRadio",
85
+ component: () => import(/* webpackChunkName: "PageRadio" */ "../views/PageRadio/PageRadio.vue"),
86
+ },
87
+ {
88
+ path: "/select",
89
+ name: "PageSelect",
90
+ component: () => import(/* webpackChunkName: "PageSelect" */ "../views/PageSelect/PageSelect.vue"),
91
+ },
92
+ {
93
+ path: "/form",
94
+ name: "PageForm",
95
+ component: () => import(/* webpackChunkName: "PageForm" */ "../views/PageForm/PageForm.vue"),
96
+ },
97
+ {
98
+ path: "/dropdown",
99
+ name: "PageDropdown",
100
+ component: () => import(/* webpackChunkName: "PageDropdown" */ "../views/PageDropdown/PageDropdown.vue"),
101
+ },
72
102
  {
73
103
  // If the routing configuration '*' reports an error, replace it with '/: catchAll(. *)'
74
104
  // caught Error: Catch all routes ("*") must now be defined using a param with a custom regexp
@@ -0,0 +1,35 @@
1
+ import ACheckbox from "../../../../src/ui/ACheckbox/ACheckbox";
2
+ import AOneCheckbox from "../../../../src/ui/AOneCheckbox/AOneCheckbox";
3
+
4
+ export default {
5
+ name: "PageCheckbox",
6
+ components: {
7
+ ACheckbox,
8
+ AOneCheckbox,
9
+ },
10
+ data() {
11
+ return {
12
+ model: false,
13
+ model1: false,
14
+ modelArr: undefined,
15
+ data: [
16
+ {
17
+ label: "Aloha 1",
18
+ id: "aloha_1",
19
+ },
20
+ {
21
+ label: "Aloha 2",
22
+ id: "aloha_2",
23
+ },
24
+ {
25
+ label: "Aloha 3",
26
+ id: "aloha_3",
27
+ },
28
+ {
29
+ label: "Aloha 4",
30
+ id: "aloha_4",
31
+ },
32
+ ],
33
+ };
34
+ },
35
+ };
@@ -0,0 +1,78 @@
1
+ div
2
+ h1 ACheckbox
3
+ a-one-checkbox(
4
+ v-model="model"
5
+ label="aloha one checkbox"
6
+ )
7
+ div model: {{ model }}
8
+ a-one-checkbox(
9
+ v-model="model1"
10
+ label="aloha one checkbox"
11
+ :is-width-auto="true"
12
+ )
13
+ div model1: {{ model1 }}
14
+ a-checkbox(
15
+ v-model="modelArr"
16
+ :data="data"
17
+ key-id="id"
18
+ key-label="label"
19
+ label="Test label"
20
+ )
21
+ div modelArr:
22
+ pre {{ modelArr }}
23
+
24
+ .a_custom_control.a_custom_checkbox
25
+ input.a_custom_control_input(
26
+ id="checkbox_0"
27
+ type="checkbox"
28
+ value="0"
29
+ )
30
+ label.a_custom_control_label(
31
+ for="checkbox_0"
32
+ ) Aloha
33
+
34
+ .a_custom_control.a_custom_checkbox
35
+ input.a_custom_control_input(
36
+ id="checkbox_1"
37
+ type="checkbox"
38
+ value="1"
39
+ :indeterminate="true"
40
+ )
41
+ label.a_custom_control_label(
42
+ for="checkbox_1"
43
+ ) Aloha indeterminate
44
+
45
+ .a_custom_control.a_custom_checkbox
46
+ input.a_custom_control_input(
47
+ id="checkbox_2"
48
+ type="checkbox"
49
+ value="1"
50
+ :disabled="true"
51
+ )
52
+ label.a_custom_control_label(
53
+ for="checkbox_2"
54
+ ) Aloha
55
+
56
+ .a_custom_control.a_custom_checkbox
57
+ input.a_custom_control_input(
58
+ id="checkbox_3"
59
+ type="checkbox"
60
+ value="1"
61
+ :checked="true"
62
+ :disabled="true"
63
+ )
64
+ label.a_custom_control_label(
65
+ for="checkbox_3"
66
+ ) Aloha
67
+
68
+ .a_custom_control.a_custom_checkbox
69
+ input.a_custom_control_input(
70
+ id="checkbox_4"
71
+ type="checkbox"
72
+ value="1"
73
+ :indeterminate="true"
74
+ :disabled="true"
75
+ )
76
+ label.a_custom_control_label(
77
+ for="checkbox_4"
78
+ ) Aloha
@@ -0,0 +1,2 @@
1
+ <template lang="pug" src="./PageCheckbox.pug"></template>
2
+ <script src="./PageCheckbox.js"></script>
@@ -14,7 +14,6 @@ export default {
14
14
  } = ConfirmAPI();
15
15
 
16
16
  const save = () => {
17
- console.log("Aloha");
18
17
  closeConfirm();
19
18
  };
20
19
 
@@ -0,0 +1,13 @@
1
+ import ADropdown from "../../../../src/ADropdown/ADropdown";
2
+
3
+ export default {
4
+ name: "PageDropdown",
5
+ components: {
6
+ ADropdown,
7
+ },
8
+ setup() {
9
+ return {
10
+
11
+ };
12
+ },
13
+ };
@@ -0,0 +1,29 @@
1
+ div
2
+ h1 ADropdown
3
+
4
+ a-dropdown(
5
+ button-class: "a_btn a_btn_link",
6
+ )
7
+ template(
8
+ v-slot:button
9
+ )
10
+ span Click me
11
+
12
+ template(
13
+ v-slot:dropdown
14
+ )
15
+ li
16
+ button.a_dropdown__item(
17
+ type="button"
18
+ ) Item 1
19
+ li.a_dropdown__divider
20
+ li
21
+ button.a_dropdown__item(
22
+ type="button"
23
+ ) Item 2
24
+ li
25
+ a.a_dropdown__item(
26
+ href="#"
27
+ ) Item 3
28
+
29
+ button.a_btn.a_btn_primary.a_ml_2 Test
@@ -0,0 +1,2 @@
1
+ <template lang="pug" src="./PageDropdown.pug"></template>
2
+ <script src="./PageDropdown.js"></script>
@@ -0,0 +1,200 @@
1
+ import AForm from "../../../../src/ui/AForm/AForm";
2
+
3
+ export default {
4
+ name: "PageForm",
5
+ components: {
6
+ AForm,
7
+ },
8
+ data() {
9
+ return {
10
+ model: undefined,
11
+ selectData: [
12
+ {
13
+ label: "Aloha 1",
14
+ id: "aloha_1",
15
+ group: "group 1",
16
+ },
17
+ {
18
+ label: "Aloha 2",
19
+ id: "aloha_2",
20
+ },
21
+ {
22
+ label: "Aloha 3",
23
+ id: "aloha_3",
24
+ group: "group 1",
25
+ },
26
+ {
27
+ label: "Aloha 4",
28
+ id: "aloha_4",
29
+ },
30
+ {
31
+ label: "Aloha 5",
32
+ id: "aloha_5",
33
+ group: "group 2",
34
+ },
35
+ {
36
+ label: "AlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAloha 6",
37
+ id: "aloha_6",
38
+ group: "group 2",
39
+ },
40
+ {
41
+ label: "AlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAloha 7",
42
+ id: "aloha_7",
43
+ group: "group 2",
44
+ },
45
+ {
46
+ label: "AlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAlohaAloha 8",
47
+ id: "aloha_8",
48
+ },
49
+ ],
50
+
51
+ errors: undefined,
52
+ };
53
+ },
54
+ computed: {
55
+ data() {
56
+ return [
57
+ {
58
+ type: "text",
59
+ label: "Aloha 1",
60
+ id: "aloha1",
61
+ classColumn: "a_column_8",
62
+ required: true,
63
+ },
64
+ {
65
+ type: "text",
66
+ label: "Aloha 2",
67
+ id: "aloha2",
68
+ classColumn: "a_column_4",
69
+ helpText: "ALOHA help!!!",
70
+ },
71
+ {
72
+ type: "select",
73
+ label: "Aloha 3",
74
+ id: "aloha3",
75
+ classColumn: "a_column_5",
76
+ keyId: "id",
77
+ keyLabel: "label",
78
+ search: true,
79
+ keyGroup: "group",
80
+ data: this.selectData,
81
+ helpText: "ALOHA help!!!",
82
+ },
83
+ {
84
+ type: "text",
85
+ label: "Aloha 4",
86
+ id: "aloha4",
87
+ classColumn: "a_column_4",
88
+ dependencies: [
89
+ {
90
+ id: "aloha3",
91
+ value: "aloha_1",
92
+ },
93
+ ],
94
+ },
95
+ {
96
+ type: "text",
97
+ label: "Aloha 5",
98
+ id: "aloha5",
99
+ classColumn: "a_column_4",
100
+ dependencies: {
101
+ id: "aloha3",
102
+ value: "aloha_2",
103
+ },
104
+ },
105
+ {
106
+ type: "textarea",
107
+ label: "Aloha 6",
108
+ id: "aloha6",
109
+ classColumn: "a_column_12",
110
+ helpText: "ALOHA help!!!",
111
+ },
112
+ {
113
+ type: "switch",
114
+ label: "Aloha 7",
115
+ id: "aloha7",
116
+ classColumn: "a_column_5",
117
+ helpText: "ALOHA help!!!",
118
+ },
119
+ {
120
+ type: "oneCheckbox",
121
+ label: "Aloha 8",
122
+ id: "aloha8",
123
+ classColumn: "a_column_5",
124
+ helpText: "ALOHA help!!!",
125
+ },
126
+ {
127
+ type: "checkbox",
128
+ label: "Aloha 9",
129
+ id: "aloha9",
130
+ classColumn: "a_column_6",
131
+ keyId: "id",
132
+ keyLabel: "label",
133
+ data: this.selectData,
134
+ helpText: "ALOHA help!!!",
135
+ },
136
+ {
137
+ type: "radio",
138
+ label: "Aloha 10",
139
+ id: "aloha10",
140
+ classColumn: "a_column_6",
141
+ keyId: "id",
142
+ keyLabel: "label",
143
+ data: this.selectData,
144
+ helpText: "ALOHA help!!!",
145
+ },
146
+ {
147
+ type: "fieldset",
148
+ label: "Aloha 11",
149
+ id: "aloha11",
150
+ classColumn: "a_column_8",
151
+ helpText: "ALOHA help!!!",
152
+ children: [
153
+ {
154
+ type: "text",
155
+ label: "Aloha 12",
156
+ id: "aloha12",
157
+ classColumn: "a_column_4",
158
+ },
159
+ {
160
+ type: "text",
161
+ label: "Aloha 13",
162
+ id: "aloha13",
163
+ classColumn: "a_column_8",
164
+ },
165
+ ],
166
+ },
167
+ {
168
+ type: "template",
169
+ id: "aloha14",
170
+ classColumn: "a_column_8",
171
+ html: "<strong>TEMPLATE</strong>",
172
+ },
173
+ ];
174
+ },
175
+ },
176
+ methods: {
177
+ validate() {
178
+ const TEXT_INVALID = "Example invalid text";
179
+ this.errors = {
180
+ aloha1: [TEXT_INVALID, TEXT_INVALID],
181
+ aloha2: [TEXT_INVALID],
182
+ aloha3: [TEXT_INVALID],
183
+ aloha4: [TEXT_INVALID],
184
+ aloha5: [TEXT_INVALID],
185
+ aloha6: [TEXT_INVALID],
186
+ aloha7: [TEXT_INVALID],
187
+ aloha8: [TEXT_INVALID],
188
+ aloha9: [TEXT_INVALID],
189
+ aloha10: [TEXT_INVALID],
190
+ aloha11: [TEXT_INVALID],
191
+ aloha12: [TEXT_INVALID],
192
+ aloha13: [TEXT_INVALID],
193
+ };
194
+ },
195
+
196
+ reset() {
197
+ this.errors = undefined;
198
+ },
199
+ },
200
+ };
@@ -0,0 +1,31 @@
1
+ div
2
+ h1 AForm
3
+
4
+ button.a_btn.a_btn_primary(
5
+ type="button"
6
+ @click="validate"
7
+ ) Validation
8
+ button.a_btn.a_btn_secondary.a_ml_2(
9
+ type="button"
10
+ @click="reset"
11
+ ) Reset
12
+ a-form(
13
+ v-model="model"
14
+ :data="data"
15
+ :errors="errors"
16
+ id-prefix="test_"
17
+ )
18
+ template(
19
+ v-slot:formPrepend
20
+ )
21
+ div
22
+ strong SLOT "formPrepend"
23
+
24
+ template(
25
+ v-slot:formAppend
26
+ )
27
+ div
28
+ strong SLOT "formAppend"
29
+
30
+ br
31
+ pre {{ model }}
@@ -0,0 +1,2 @@
1
+ <template lang="pug" src="./PageForm.pug"></template>
2
+ <script src="./PageForm.js"></script>
@@ -1,5 +1,5 @@
1
1
  import AInput from "../../../../src/ui/AInput/AInput";
2
- import ATextarea from "../../../../src/ATextarea/ATextarea";
2
+ import ATextarea from "../../../../src/ui/ATextarea/ATextarea";
3
3
 
4
4
 
5
5
  export default {
@@ -12,6 +12,7 @@ export default {
12
12
  return {
13
13
  model1: "aloha",
14
14
  model2: "hola",
15
+ model3: "",
15
16
  };
16
17
  },
17
18
  methods: {
@@ -22,4 +22,15 @@ div
22
22
  div model2:
23
23
  pre {{ model2 }}
24
24
 
25
+ h2 Textarea 2
26
+ a-textarea(
27
+ id="textarea3"
28
+ v-model="model3"
29
+ type="text"
30
+ label="Textarea 2"
31
+ :required="true"
32
+ )
33
+ div model3:
34
+ pre {{ model3 }}
35
+
25
36
 
@@ -0,0 +1,34 @@
1
+ import ANotificationAPI from "../../../../src/compositionAPI/ANotificationAPI";
2
+
3
+ export default {
4
+ name: "PageNotification",
5
+ setup() {
6
+ const {
7
+ addNotification,
8
+ } = ANotificationAPI();
9
+
10
+ const addNotificationLocal = type => {
11
+ addNotification({
12
+ text: type,
13
+ type,
14
+ });
15
+ };
16
+
17
+ return {
18
+ addNotificationLocal,
19
+ };
20
+ },
21
+ data() {
22
+ return {
23
+ types: [
24
+ "primary",
25
+ "secondary",
26
+ "success",
27
+ "danger",
28
+ "warning",
29
+ "info",
30
+ "dark",
31
+ ],
32
+ };
33
+ },
34
+ };
@@ -0,0 +1,9 @@
1
+ div
2
+ h1 ANotification
3
+ button.a_btn.a_mr_2(
4
+ v-for="type in types"
5
+ :key="type"
6
+ :class="'a_btn_' + type"
7
+ type="button"
8
+ @click="addNotificationLocal(type)"
9
+ ) Add Notification {{ type }}
@@ -0,0 +1,2 @@
1
+ <template lang="pug" src="./PageNotification.pug"></template>
2
+ <script src="./PageNotification.js"></script>
@@ -0,0 +1,31 @@
1
+ import ARadio from "../../../../src/ui/ARadio/ARadio";
2
+
3
+ export default {
4
+ name: "PageRadio",
5
+ components: {
6
+ ARadio,
7
+ },
8
+ data() {
9
+ return {
10
+ model: undefined,
11
+ data: [
12
+ {
13
+ label: "Aloha 1",
14
+ id: "aloha_1",
15
+ },
16
+ {
17
+ label: "Aloha 2",
18
+ id: "aloha_2",
19
+ },
20
+ {
21
+ label: "Aloha 3",
22
+ id: "aloha_3",
23
+ },
24
+ {
25
+ label: "Aloha 4",
26
+ id: "aloha_4",
27
+ },
28
+ ],
29
+ };
30
+ },
31
+ };
@@ -0,0 +1,54 @@
1
+ div
2
+ h1 ARadio
3
+ a-radio(
4
+ v-model="model"
5
+ :data="data"
6
+ key-id="id"
7
+ key-label="label"
8
+ label="Test label"
9
+ )
10
+ div model: {{ model }}
11
+
12
+ .a_custom_control.a_custom_radio
13
+ input.a_custom_control_input(
14
+ id="checkbox_0"
15
+ type="radio"
16
+ value="0"
17
+ )
18
+ label.a_custom_control_label(
19
+ for="checkbox_0"
20
+ ) Aloha
21
+
22
+ .a_custom_control.a_custom_radio
23
+ input.a_custom_control_input(
24
+ id="checkbox_1"
25
+ type="radio"
26
+ value="0"
27
+ :checked="true"
28
+ )
29
+ label.a_custom_control_label(
30
+ for="checkbox_1"
31
+ ) Aloha
32
+
33
+ .a_custom_control.a_custom_radio
34
+ input.a_custom_control_input(
35
+ id="checkbox_2"
36
+ type="radio"
37
+ value="0"
38
+ :checked="true"
39
+ :disabled="true"
40
+ )
41
+ label.a_custom_control_label(
42
+ for="checkbox_2"
43
+ ) Aloha
44
+
45
+ .a_custom_control.a_custom_radio
46
+ input.a_custom_control_input(
47
+ id="checkbox_3"
48
+ type="radio"
49
+ value="0"
50
+ :disabled="true"
51
+ )
52
+ label.a_custom_control_label(
53
+ for="checkbox_3"
54
+ ) Aloha
@@ -0,0 +1,2 @@
1
+ <template lang="pug" src="./PageRadio.pug"></template>
2
+ <script src="./PageRadio.js"></script>