nodality 1.0.215 → 1.0.217

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 (275) hide show
  1. package/dist/animator.cjs.js +1 -1
  2. package/dist/animator.cjs.js.LICENSE.txt +1 -1
  3. package/dist/animator.esm.js +1 -1
  4. package/dist/animator.esm.js.LICENSE.txt +1 -1
  5. package/dist/audionew.cjs.js +1 -1
  6. package/dist/audionew.cjs.js.LICENSE.txt +1 -1
  7. package/dist/audionew.esm.js +1 -1
  8. package/dist/audionew.esm.js.LICENSE.txt +1 -1
  9. package/dist/base.cjs.js +1 -1
  10. package/dist/base.cjs.js.LICENSE.txt +1 -1
  11. package/dist/base.esm.js +1 -1
  12. package/dist/base.esm.js.LICENSE.txt +1 -1
  13. package/dist/beta-desktop-bar.cjs.js +1 -1
  14. package/dist/beta-desktop-bar.cjs.js.LICENSE.txt +1 -1
  15. package/dist/beta-desktop-bar.esm.js +1 -1
  16. package/dist/beta-desktop-bar.esm.js.LICENSE.txt +1 -1
  17. package/dist/beta-mobile-bar.cjs.js +1 -1
  18. package/dist/beta-mobile-bar.cjs.js.LICENSE.txt +1 -1
  19. package/dist/beta-mobile-bar.esm.js +1 -1
  20. package/dist/beta-mobile-bar.esm.js.LICENSE.txt +1 -1
  21. package/dist/bundle.umd.js +1 -1
  22. package/dist/bundle.umd.js.LICENSE.txt +1 -1
  23. package/dist/button.cjs.js +1 -1
  24. package/dist/button.cjs.js.LICENSE.txt +1 -1
  25. package/dist/button.esm.js +1 -1
  26. package/dist/button.esm.js.LICENSE.txt +1 -1
  27. package/dist/card-getter.cjs.js.LICENSE.txt +1 -1
  28. package/dist/card-getter.esm.js.LICENSE.txt +1 -1
  29. package/dist/center.cjs.js +1 -1
  30. package/dist/center.cjs.js.LICENSE.txt +1 -1
  31. package/dist/center.esm.js +1 -1
  32. package/dist/center.esm.js.LICENSE.txt +1 -1
  33. package/dist/checkbox.cjs.js +1 -1
  34. package/dist/checkbox.cjs.js.LICENSE.txt +1 -1
  35. package/dist/checkbox.esm.js +1 -1
  36. package/dist/checkbox.esm.js.LICENSE.txt +1 -1
  37. package/dist/code.cjs.js +1 -1
  38. package/dist/code.cjs.js.LICENSE.txt +1 -1
  39. package/dist/code.esm.js +1 -1
  40. package/dist/code.esm.js.LICENSE.txt +1 -1
  41. package/dist/container.cjs.js +1 -1
  42. package/dist/container.cjs.js.LICENSE.txt +1 -1
  43. package/dist/container.esm.js +1 -1
  44. package/dist/container.esm.js.LICENSE.txt +1 -1
  45. package/dist/data-list.cjs.js.LICENSE.txt +1 -1
  46. package/dist/data-list.esm.js.LICENSE.txt +1 -1
  47. package/dist/designer.cjs.js +1 -1
  48. package/dist/designer.cjs.js.LICENSE.txt +1 -1
  49. package/dist/designer.esm.js +1 -1
  50. package/dist/designer.esm.js.LICENSE.txt +1 -1
  51. package/dist/element-mapper.cjs.js +1 -1
  52. package/dist/element-mapper.cjs.js.LICENSE.txt +1 -1
  53. package/dist/element-mapper.esm.js +1 -1
  54. package/dist/element-mapper.esm.js.LICENSE.txt +1 -1
  55. package/dist/finalresult.esm.js +1 -1
  56. package/dist/finalresult.esm.js.LICENSE.txt +1 -1
  57. package/dist/flex-card.cjs.js +1 -1
  58. package/dist/flex-card.cjs.js.LICENSE.txt +1 -1
  59. package/dist/flex-card.esm.js +1 -1
  60. package/dist/flex-card.esm.js.LICENSE.txt +1 -1
  61. package/dist/flex-grid.cjs.js +1 -1
  62. package/dist/flex-grid.cjs.js.LICENSE.txt +1 -1
  63. package/dist/flex-grid.esm.js +1 -1
  64. package/dist/flex-grid.esm.js.LICENSE.txt +1 -1
  65. package/dist/flex-row.cjs.js +1 -1
  66. package/dist/flex-row.cjs.js.LICENSE.txt +1 -1
  67. package/dist/flex-row.esm.js +1 -1
  68. package/dist/flex-row.esm.js.LICENSE.txt +1 -1
  69. package/dist/floating-input.cjs.js +1 -1
  70. package/dist/floating-input.cjs.js.LICENSE.txt +1 -1
  71. package/dist/floating-input.esm.js +1 -1
  72. package/dist/floating-input.esm.js.LICENSE.txt +1 -1
  73. package/dist/free.cjs.js +1 -1
  74. package/dist/free.cjs.js.LICENSE.txt +1 -1
  75. package/dist/free.esm.js +1 -1
  76. package/dist/free.esm.js.LICENSE.txt +1 -1
  77. package/dist/horizontal-scroller.cjs.js.LICENSE.txt +1 -1
  78. package/dist/horizontal-scroller.esm.js.LICENSE.txt +1 -1
  79. package/dist/image-picker.cjs.js +1 -1
  80. package/dist/image-picker.cjs.js.LICENSE.txt +1 -1
  81. package/dist/image-picker.esm.js +1 -1
  82. package/dist/image-picker.esm.js.LICENSE.txt +1 -1
  83. package/dist/image.cjs.js +1 -1
  84. package/dist/image.cjs.js.LICENSE.txt +1 -1
  85. package/dist/image.esm.js +1 -1
  86. package/dist/image.esm.js.LICENSE.txt +1 -1
  87. package/dist/index.cjs.js +1 -1
  88. package/dist/index.cjs.js.LICENSE.txt +1 -1
  89. package/dist/index.esm.js +1 -1
  90. package/dist/index.esm.js.LICENSE.txt +1 -1
  91. package/dist/keyframe-animation.cjs.js.LICENSE.txt +1 -1
  92. package/dist/keyframe-animation.esm.js.LICENSE.txt +1 -1
  93. package/dist/link-getter.cjs.js +1 -1
  94. package/dist/link-getter.cjs.js.LICENSE.txt +1 -1
  95. package/dist/link-getter.esm.js +1 -1
  96. package/dist/link-getter.esm.js.LICENSE.txt +1 -1
  97. package/dist/link.cjs.js +1 -1
  98. package/dist/link.cjs.js.LICENSE.txt +1 -1
  99. package/dist/link.esm.js +1 -1
  100. package/dist/link.esm.js.LICENSE.txt +1 -1
  101. package/dist/meta-adder.cjs.js.LICENSE.txt +1 -1
  102. package/dist/meta-adder.esm.js.LICENSE.txt +1 -1
  103. package/dist/modal-2025.cjs.js.LICENSE.txt +1 -1
  104. package/dist/modal-2025.esm.js.LICENSE.txt +1 -1
  105. package/dist/multiswitcher.cjs.js +1 -1
  106. package/dist/multiswitcher.cjs.js.LICENSE.txt +1 -1
  107. package/dist/multiswitcher.esm.js +1 -1
  108. package/dist/multiswitcher.esm.js.LICENSE.txt +1 -1
  109. package/dist/new-nav-bar.cjs.js +1 -1
  110. package/dist/new-nav-bar.cjs.js.LICENSE.txt +1 -1
  111. package/dist/new-nav-bar.esm.js +1 -1
  112. package/dist/new-nav-bar.esm.js.LICENSE.txt +1 -1
  113. package/dist/picker.cjs.js +1 -1
  114. package/dist/picker.cjs.js.LICENSE.txt +1 -1
  115. package/dist/picker.esm.js +1 -1
  116. package/dist/picker.esm.js.LICENSE.txt +1 -1
  117. package/dist/progress.cjs.js.LICENSE.txt +1 -1
  118. package/dist/progress.esm.js.LICENSE.txt +1 -1
  119. package/dist/radio.cjs.js.LICENSE.txt +1 -1
  120. package/dist/radio.esm.js.LICENSE.txt +1 -1
  121. package/dist/range.cjs.js.LICENSE.txt +1 -1
  122. package/dist/range.esm.js.LICENSE.txt +1 -1
  123. package/dist/scroll-video.cjs.js.LICENSE.txt +1 -1
  124. package/dist/scroll-video.esm.js.LICENSE.txt +1 -1
  125. package/dist/side-bar.cjs.js.LICENSE.txt +1 -1
  126. package/dist/side-bar.esm.js.LICENSE.txt +1 -1
  127. package/dist/side-nav-bar.cjs.js +1 -1
  128. package/dist/side-nav-bar.cjs.js.LICENSE.txt +1 -1
  129. package/dist/side-nav-bar.esm.js +1 -1
  130. package/dist/side-nav-bar.esm.js.LICENSE.txt +1 -1
  131. package/dist/simple-bar.cjs.js +1 -1
  132. package/dist/simple-bar.cjs.js.LICENSE.txt +1 -1
  133. package/dist/simple-bar.esm.js +1 -1
  134. package/dist/simple-bar.esm.js.LICENSE.txt +1 -1
  135. package/dist/slider-2025.cjs.js +1 -1
  136. package/dist/slider-2025.cjs.js.LICENSE.txt +1 -1
  137. package/dist/slider-2025.esm.js +1 -1
  138. package/dist/slider-2025.esm.js.LICENSE.txt +1 -1
  139. package/dist/spacer.cjs.js.LICENSE.txt +1 -1
  140. package/dist/spacer.esm.js.LICENSE.txt +1 -1
  141. package/dist/stack.cjs.js.LICENSE.txt +1 -1
  142. package/dist/stack.esm.js.LICENSE.txt +1 -1
  143. package/dist/stacker.cjs.js.LICENSE.txt +1 -1
  144. package/dist/stacker.esm.js.LICENSE.txt +1 -1
  145. package/dist/table.cjs.js +1 -1
  146. package/dist/table.cjs.js.LICENSE.txt +1 -1
  147. package/dist/table.esm.js +1 -1
  148. package/dist/table.esm.js.LICENSE.txt +1 -1
  149. package/dist/text-field.cjs.js +1 -1
  150. package/dist/text-field.cjs.js.LICENSE.txt +1 -1
  151. package/dist/text-field.esm.js +1 -1
  152. package/dist/text-field.esm.js.LICENSE.txt +1 -1
  153. package/dist/text.cjs.js +1 -1
  154. package/dist/text.cjs.js.LICENSE.txt +1 -1
  155. package/dist/text.esm.js +1 -1
  156. package/dist/text.esm.js.LICENSE.txt +1 -1
  157. package/dist/theme.cjs.js.LICENSE.txt +1 -1
  158. package/dist/theme.esm.js.LICENSE.txt +1 -1
  159. package/dist/transform-anim.cjs.js.LICENSE.txt +1 -1
  160. package/dist/transform-anim.esm.js.LICENSE.txt +1 -1
  161. package/dist/ulist.cjs.js +1 -1
  162. package/dist/ulist.cjs.js.LICENSE.txt +1 -1
  163. package/dist/ulist.esm.js +1 -1
  164. package/dist/ulist.esm.js.LICENSE.txt +1 -1
  165. package/dist/video.cjs.js +1 -1
  166. package/dist/video.cjs.js.LICENSE.txt +1 -1
  167. package/dist/video.esm.js +1 -1
  168. package/dist/video.esm.js.LICENSE.txt +1 -1
  169. package/dist/wrap.cjs.js.LICENSE.txt +1 -1
  170. package/dist/wrap.esm.js.LICENSE.txt +1 -1
  171. package/dist/zoom-card.cjs.js +1 -1
  172. package/dist/zoom-card.cjs.js.LICENSE.txt +1 -1
  173. package/dist/zoom-card.esm.js +1 -1
  174. package/dist/zoom-card.esm.js.LICENSE.txt +1 -1
  175. package/layout/animator.js +321 -1987
  176. package/layout/audio.js +1 -5
  177. package/layout/audionew.js +1 -1
  178. package/layout/base.js +3 -17
  179. package/layout/beta-desktop-bar.js +1 -1
  180. package/layout/beta-mobile-bar.js +2 -9
  181. package/layout/button.js +7 -30
  182. package/layout/center.js +3 -38
  183. package/layout/checkbox.js +1 -5
  184. package/layout/circle.js +9 -8
  185. package/layout/code.js +1 -1
  186. package/layout/container.js +22 -53
  187. package/layout/dropdown-2025.js +1 -1
  188. package/layout/flex-card.js +20 -10
  189. package/layout/flex-grid.js +1 -5
  190. package/layout/flex-row.js +2 -75
  191. package/layout/form-components/custom.js +1 -1
  192. package/layout/form-components/data-list.js +1 -1
  193. package/layout/form-components/floating-input.js +1 -1
  194. package/layout/form-components/form-all.js +1 -1
  195. package/layout/form-components/form.js +1 -1
  196. package/layout/form-components/image-picker.js +1 -1
  197. package/layout/form-components/picker.js +1 -1
  198. package/layout/form-components/radio.js +1 -1
  199. package/layout/form-components/radiogroup.js +1 -1
  200. package/layout/form-components/range.js +1 -1
  201. package/layout/free.js +1 -1
  202. package/layout/grid-switcher.js +5 -12
  203. package/layout/grid.js +1 -40
  204. package/layout/horizontal-scroller.js +1 -1
  205. package/layout/image.js +24 -115
  206. package/layout/index.js +1 -1
  207. package/layout/link.js +19 -64
  208. package/layout/list.js +1 -1
  209. package/layout/meta-adder.js +1 -1
  210. package/layout/modal-2025.js +1 -1
  211. package/layout/multiswitcher.js +1 -1
  212. package/layout/nav-bar.js +4 -20
  213. package/layout/nav-factor/custom-div.js +1 -1
  214. package/layout/new-nav-bar.js +1 -16
  215. package/layout/polygon.js +7 -12
  216. package/layout/prerender-site.js +1 -1
  217. package/layout/prerender.js +1 -1
  218. package/layout/progress.js +1 -1
  219. package/layout/row.js +1 -4
  220. package/layout/scroll-video.js +1 -1
  221. package/layout/side-bar.js +1 -1
  222. package/layout/side-nav-bar.js +1 -1
  223. package/layout/simple-bar.js +1 -1
  224. package/layout/slider-2025.js +1 -1
  225. package/layout/spacer.js +1 -1
  226. package/layout/stack.js +1 -1
  227. package/layout/svg.js +1 -1
  228. package/layout/switcher.js +1 -1
  229. package/layout/table.js +1 -1
  230. package/layout/text-field.js +18 -38
  231. package/layout/text.js +4 -617
  232. package/layout/ulist.js +1 -25
  233. package/layout/video.js +1 -1
  234. package/layout/wrap.js +1 -1
  235. package/layout/zoom-card.js +1 -1
  236. package/lib/card-getter.js +1 -1
  237. package/lib/data.js +1 -1
  238. package/lib/designer.js +1 -1
  239. package/lib/element-mapper.js +1 -1
  240. package/lib/keyframe-animation.js +1 -1
  241. package/lib/link-getter.js +1 -1
  242. package/lib/raster-ops.js +1 -1
  243. package/lib/scroll-video.js +1 -1
  244. package/lib/seo.js +1 -1
  245. package/lib/stacker.js +1 -1
  246. package/lib/theme.js +1 -1
  247. package/lib/transform-anim.js +1 -1
  248. package/package.json +1 -1
  249. package/dist/dropdown.cjs.js +0 -2
  250. package/dist/dropdown.cjs.js.LICENSE.txt +0 -5
  251. package/dist/dropdown.esm.js +0 -2
  252. package/dist/dropdown.esm.js.LICENSE.txt +0 -5
  253. package/layout/base-2.js +0 -97
  254. package/layout/box.js +0 -35
  255. package/layout/cards.js +0 -143
  256. package/layout/clean-row.js +0 -686
  257. package/layout/custom.js +0 -297
  258. package/layout/div-image.js +0 -167
  259. package/layout/dropdown.js +0 -158
  260. package/layout/empty-element.js +0 -27
  261. package/layout/external-stylesheet.js +0 -25
  262. package/layout/footer.js +0 -89
  263. package/layout/grid-new.js +0 -301
  264. package/layout/group.js +0 -129
  265. package/layout/header.js +0 -181
  266. package/layout/image-old.js +0 -453
  267. package/layout/label.js +0 -56
  268. package/layout/list-OLD.js +0 -6
  269. package/layout/modernwrap.js +0 -97
  270. package/layout/multiswitcherBeta.js +0 -69
  271. package/layout/navBar-OLD.js +0 -266
  272. package/layout/new-flat-adder.js +0 -47
  273. package/layout/offset-container.js +0 -394
  274. package/layout/saved-new-nav-bar.js +0 -437
  275. package/layout/without-new.js +0 -66
@@ -1,686 +0,0 @@
1
- /*!
2
- * nodality v1.0.215
3
- * (c) 2026 Filip Vabrousek
4
- * License: MIT
5
- */
6
-
7
- import {Animator} from "./animator.js";
8
-
9
-
10
- class CleanRow extends Animator {
11
- constructor(frs, saveEl) {
12
- super();
13
- this.code = []; // 191455
14
- this.saveEl = saveEl;
15
- this.frs = frs;
16
- this.res = null;
17
- this.setup();
18
- this.responsive();
19
- this.code.push(", new FlexRow()");
20
- }
21
-
22
- getType(){
23
- return "FlexRowLayoutElement";
24
- }
25
-
26
-
27
-
28
- set(options){
29
-
30
- let obj = options;
31
-
32
-
33
- if (obj && obj.id && obj.stroke || obj && obj.id && obj.gradient || obj && obj.id && obj.span || obj && obj.id && obj.backgroundOp){
34
-
35
- if (obj.gradient){
36
- this.globalGradient = obj.gradient.op.gradient;
37
-
38
- } // OK
39
-
40
- if (obj.stroke){
41
- super.setAny({globalBlast: `${obj.stroke.op.width} ${obj.stroke.op.color}`});
42
- }
43
-
44
- // Filter just the elements with layout element
45
- let ft = [obj.stroke, obj.gradient, obj.animation, obj.span, obj.backgroundOp]//obj.gradient.filter(el => el.op.name !== "layout");
46
- ft = ft.filter(el => el != undefined);
47
-
48
- let arr = [];
49
-
50
- for (var i = 0; i < ft.length; i++){
51
- arr.push({
52
- range: ft[i].range,
53
- log: ft[i].op.name,
54
- target: ft[i].target
55
- });
56
- }
57
-
58
- this.res.setAttribute("id", obj.id);
59
- this.betaReact(arr, obj.id);
60
- // this.protoReact(arr, obj.id);
61
- }
62
-
63
- //-------------------------------------------------------------------------------------------
64
- if (options.padding){
65
- this.padding(options.padding);
66
- }
67
-
68
- if (options.background){
69
- this.res.style.backgroundColor = "#ecf0f1";
70
- this.res.style.cornerRadius = "#3rem";
71
- }
72
-
73
- if (options.alignTo){
74
-
75
- this.res.style.justifyContent = options.alignTo;
76
-
77
- }
78
-
79
-
80
-
81
-
82
-
83
-
84
- if (options.background){
85
- this.res.style.backgroundColor = options.background;
86
- this.code.push(`\n background: "${options.background}",`);
87
- }
88
-
89
- if (options.justify){
90
- this.res.style.justifyContent = options.justify;
91
- this.code.push(`\n justify: "${options.justify}",`);
92
- }
93
-
94
- if (options.border) {
95
-
96
- if (options.border[0] === "top") {
97
- this.res.style.borderTop = `${options.border[1]} solid white`;
98
- // border: ["top", "1px"],
99
- }
100
-
101
- if (options.border[0] === "all") {
102
- this.res.style.border = `${options.border[1]} solid white`;
103
- // border: ["top", "1px"],
104
- }
105
-
106
-
107
-
108
- this.code.push(`\n border: ["${options.border[0]}", "${options.border[1]}"],`);
109
- }
110
-
111
- if (options.borderObj){
112
- this.res.style.border = `${options.borderObj.width} solid ${options.borderObj.color}`
113
- this.res.style.borderRadius = options.borderObj.radius;
114
-
115
- let stringified = JSON.stringify(options.borderObj);
116
- this.code.push(`\n borderObj: ${stringified},`);
117
-
118
- /*borderObj: {
119
- side: "all",
120
- width: "3px",
121
- color: "rgba(236, 227, 215, 0.5)"
122
- },*/
123
- }
124
-
125
- options.width && (this.res.style.width = options.width);
126
- options.width && this.code.push(`\n width: "${options.width}",`);
127
-
128
- options.height && (this.res.style.height = options.height);
129
- options.height && this.code.push(`\n height: "${options.height}",`);
130
-
131
-
132
- if (options.align){
133
- let stringified = JSON.stringify(options.align);
134
- this.res.style.alignItems = "flex-start";
135
- this.code.push(`\n alignIts: "flex-start",`);
136
- this.res.style.alignItems = "flex-start";
137
- }
138
-
139
- // options.align && alert("K")
140
-
141
- options.wrap && this.wrap();
142
- options.wrap && this.code.push(`\n wrap: true,`)
143
-
144
- if (options.alignIts){
145
- let stringified = JSON.stringify(options.alignIts);
146
- this.res.style.alignItems = "flex-start";
147
- this.code.push(`\n alignIts: ${stringified},`);
148
-
149
- }
150
- // options.alignIts && alert("J");
151
- //alignIts: "flex-start",
152
-
153
- options.owrap && this.onlyWrap();
154
- options.owrap && this.code.push(`\n owrap: true,`)
155
-
156
- if (options.owrap != undefined){
157
-
158
-
159
- if (options.owrap === false){ // DANGEROUS
160
- // alert("FIRES AFTER OJ");
161
- this.res.style.flexWrap = "nowrap";
162
- this.res.style.background = "yellow";
163
- }
164
- }
165
-
166
- // console.warn(options);
167
-
168
- // options.columnAlways && (this.columnAlways = true);
169
- options.columnAlways && alert("JIJ" + options.columnAlways);
170
-
171
- options.toColumn && this.toColumn(options.toColumn); // OK
172
-
173
-
174
- options.column && this.makeCol(); // OK
175
-
176
-
177
-
178
- if (options.colat){
179
-
180
- options.colat && this.toColumnAt(options.colat);
181
- this.code.push(`\n colat: "${options.colat}",`);
182
- }
183
-
184
-
185
- //alert(options.arrpad);
186
-
187
-
188
-
189
- // alert(options.multipad);
190
-
191
-
192
- if (options.align){
193
- //alert("K")
194
-
195
- this.makeJustify(options.justify);
196
- // this.setAlign(options.align);
197
- }
198
-
199
- if (options.justify){
200
- this.makeAlign(options.justify);
201
- // this.setAlign(options.align);
202
- }
203
- //this.res.style.justifyContent = "flex-start";
204
- //alert(this.res.style.justifyContent);
205
- if (options.justifo === "flex-start"){
206
-
207
- this.res.style.justifyContent = "flex-start";
208
- } else {
209
- //alert(options.justify);
210
- }
211
-
212
- options.radius && (this.res.style.borderRadius = "1rem");
213
- //---------------------------------------------------------------------------------
214
-
215
-
216
-
217
-
218
-
219
-
220
- return this;
221
- }
222
-
223
-
224
-
225
-
226
- setArea(area){
227
- this.res.style.gridArea = area;
228
- return this;
229
- }
230
-
231
- toColumnAt(at){ // THIS IS THE ONE!!!
232
-
233
-
234
- if (!this.columnAlways){
235
- // alert(this.columnAlways);
236
-
237
-
238
- const toCol = () => {
239
-
240
- let media = window.matchMedia(`(max-width: ${at})`);
241
- let mobileMedia = window.matchMedia(`(max-device-width: 415px)`);
242
-
243
- if (media.matches || mobileMedia.matches){
244
-
245
- this.res.style.flexDirection = "column";
246
- } else {
247
- this.res.style.flexDirection = "row";
248
-
249
- }
250
- }
251
-
252
- toCol();
253
- window.addEventListener("resize", toCol);
254
- }
255
-
256
-
257
-
258
-
259
-
260
- return this;
261
- }
262
-
263
- // 1:32:56, 1:33:24 talk 17/08
264
-
265
-
266
- onlyWrap(){
267
- this.res.style.flexWrap = "wrap";
268
- return this;
269
- }
270
-
271
- wrap(){
272
- this.res.style.flexWrap = "wrap";
273
- this.res.style.justifyContent = "space-between";
274
- return this;
275
- }
276
-
277
-
278
- aligns(st){
279
-
280
- if (st === "start"){
281
- this.res.style.alignItems = "flex-start";
282
- }
283
-
284
-
285
- if (st === "end"){
286
- this.res.style.alignItems = "flex-end";
287
- }
288
-
289
- if (st === "center"){
290
- this.res.style.alignItems = "center";
291
- }
292
-
293
-
294
- // alert(st);
295
-
296
- return this;
297
- }
298
-
299
-
300
- toColumn(at){
301
- alert("ON")
302
-
303
- const toCol = () => {
304
- let media = window.matchMedia(`(max-width: ${at})`);
305
- let mobileMedia = window.matchMedia(`(max-device-width: 415px)`);
306
- // alert(media);
307
-
308
- //console.log(mobileMedia);
309
-
310
- if (media.matches || mobileMedia.matches){
311
- this.res.style.flexDirection = "column";
312
- } else {
313
- this.res.style.flexDirection = "row";
314
-
315
- }
316
- }
317
-
318
- toCol();
319
- window.addEventListener("resize", toCol);
320
-
321
-
322
-
323
-
324
-
325
- return this;
326
- }
327
-
328
-
329
- toCode(){
330
- return this.code; // 21:40:09
331
- }
332
-
333
-
334
- borderAround(data){
335
- this.res.style.border = data;
336
- return this;
337
- }
338
-
339
-
340
-
341
- cornerRadius(el){
342
- this.res.style.borderRadius = el;
343
- return this;
344
- }
345
-
346
-
347
-
348
-
349
- makeJustify(opt){
350
- //alert("KJ");
351
- if (opt === "start"){
352
-
353
- // alert("HJ");
354
- this.res.style.justifyContent = "flex-start";
355
- }
356
-
357
- return this;
358
- }
359
-
360
-
361
- makeAlign(opt){
362
- //alert("KJ");
363
- if (opt === "center"){
364
-
365
- // alert("HJ");
366
- this.res.style.alignItems = "center";
367
- } else {
368
-
369
-
370
-
371
-
372
-
373
- //alert(opt)
374
- this.res.style.justifyContent = opt;
375
- // let stringified = JSON.stringify(options.alignTo);
376
- //this.code.push(`\n alignTo: "${stringified}",`);
377
- }
378
-
379
- return this;
380
- }
381
-
382
-
383
- makeCol(){
384
- this.res.style.flexDirection = "column";
385
- return this;
386
- }
387
-
388
-
389
-
390
-
391
-
392
- padding(vals){
393
- this.res.style.padding = vals;
394
- return this;
395
- }
396
-
397
-
398
- toColumn(){
399
- this.res.style.flexDirection = "column";
400
- return this;
401
- }
402
-
403
-
404
-
405
- setClass(classa){
406
- this.res.setAttribute("class", classa);
407
- return this;
408
- }
409
-
410
-
411
- setup() {
412
- let flex = document.createElement("div");
413
- flex.style.display = "flex";
414
- flex.style.justifyContent = "space-around";
415
- flex.style.alignItems = "center";
416
- flex.style.margin = 0;
417
- // flex.style.width = "100%";
418
- this.res = flex;
419
-
420
-
421
- //console.log("FREDERICK!");
422
- //console.log(this);
423
-
424
-
425
-
426
- return this;
427
-
428
- // 19:36:06 Houdini Roger kilimanjaro 06/03 audiovisual
429
- }
430
-
431
-
432
- noSpaceAround(){
433
- this.res.style.justifyContent = "";
434
- return this;
435
- }
436
-
437
-
438
-
439
-
440
- itemAlignCenter(){
441
- this.res.style.justifyContent = "center";
442
- this.res.style.alignItems = "center";
443
- return this;
444
- }
445
-
446
-
447
- /*
448
- {
449
- if
450
- }
451
-
452
- */
453
-
454
-
455
-
456
-
457
- frame(obj){
458
- this.res.style.width = obj.width;
459
- this.res.style.height = obj.height;
460
-
461
-
462
- let media = window.matchMedia("(max-device-width: 415px)");
463
-
464
- if (media.matches && obj.mobile){
465
- this.res.style.width = obj.mobile
466
- }
467
-
468
- return this;
469
- }
470
-
471
- background(color){
472
- this.res.style.background = color;
473
- return this;
474
- }
475
-
476
- radius(val){
477
- this.res.style.borderRadius = `${val}px`;
478
- return this;
479
- }
480
-
481
- shadow(x, y, radius){
482
- this.res.style.boxShadow = "0px 1px 10px 0px rgb(145 145 145)"; //`${x}px ${y}px ${radius}px #000`;
483
- return this;
484
- }
485
-
486
- onTap(e){
487
- this.res.addEventListener("click", e);
488
- return this;
489
- }
490
-
491
-
492
- items(arr) {
493
- //console.log("2 images enter flex row")
494
- //console.warn(arr); // 2 images enter flexRow or there is problem in FlexRow code gen
495
-
496
- //console.warn(this.res);
497
-
498
- this.els = arr;
499
-
500
- this.code.push(".items([");
501
-
502
- /*
503
- console.log("/FL ITEM---");*/
504
-
505
- for (var i = 0; i < arr.length; i++) {
506
-
507
-
508
-
509
-
510
- // console.error(arr[i].render);
511
-
512
- if (arr[i] != undefined){
513
- if (arr[i].render instanceof Function){ // 170736
514
- let r = arr[i].render();
515
- // r.style.width = "100%";
516
- //r.style.flex = 1;
517
- this.res.appendChild(r);
518
- } else {
519
- this.res.appendChild(arr[i]);
520
- }
521
- }
522
-
523
-
524
-
525
- //this.code.push("L");
526
-
527
-
528
- /* if (arr[i].toCode instanceof Array){
529
- // console.warn(arr[i].toCode().flatMap(x => x));
530
- this.code.push(arr[i].toCode().flatMap(x => x));
531
- } else {
532
- if (arr[i].toCode){
533
- this.code.push(arr[i].toCode());
534
-
535
-
536
-
537
-
538
- }
539
- }*/
540
-
541
-
542
- if (arr[i] != undefined){
543
-
544
-
545
-
546
-
547
- if (arr[i].render instanceof Function){
548
- let item = arr[i].render();//.render();
549
- this.res.appendChild(item);
550
-
551
-
552
- if (arr[i].toCode !== undefined){
553
- // console.log("arr[i]");
554
- // console.log(arr[i]);
555
- this.code.push(arr[i].toCode().flatMap(l=>l)); // 20:10:00 Nice!
556
- // 12:25:10 Wow!!!
557
-
558
-
559
- // Image codegen problem
560
- }
561
- }
562
- }
563
-
564
-
565
-
566
-
567
- //console.log("FREDERICK!");
568
- //console.log(this.code);
569
-
570
- //this.code = this.code.flatMap(x => x).flatMap(x => x);
571
- }
572
-
573
-
574
- this.code.push("])");
575
-
576
-
577
- // this.code = this.code.flatMap(x => x);
578
- // console.log(this.code);
579
-
580
-
581
-
582
- return this;
583
- }
584
-
585
-
586
-
587
- /*
588
-
589
- this.code.push(".add([ \n");
590
- for (var i = 0; i < els.length; i++){
591
- let item = els[i].render();//.render();
592
- this.res.appendChild(item);
593
-
594
-
595
- if (els[i].toCode !== undefined){
596
-
597
- this.code.push(els[i].toCode().flatMap(l=>l)); // 20:10:00 Nice!
598
- // 12:25:10 Wow!!!
599
-
600
-
601
- }
602
- }
603
-
604
- //122616 06/03 Houdini M2 chip
605
- this.code.push("])");
606
-
607
-
608
- return this;
609
- */
610
-
611
-
612
-
613
-
614
- adjustRatiosForLayout(){
615
-
616
- if (this.els[1].getWidth == undefined){
617
- return this;
618
- }
619
-
620
- if (this.els[1].getHeight == undefined){
621
- return this; // 171653 fix
622
- } // 171354
623
-
624
- window.addEventListener("resize", () => {
625
- this.resizeValues();
626
- });
627
-
628
-
629
- this.resizeValues();
630
-
631
-
632
-
633
-
634
- // 18:29:04
635
-
636
- return this;
637
- }
638
-
639
-
640
- resizeValues(){
641
- let newWidth = window.innerWidth * 0.7;
642
- let aspect = (this.els[1].getHeight() / this.els[1].getWidth());
643
- let goal = newWidth * aspect;
644
-
645
- this.res.children[0].style.height = `${goal}px`;
646
- this.res.children[0].style.width = `30%`;
647
- this.res.children[1].style.width = `70%`;
648
- }
649
-
650
- responsive(h){
651
- let media = window.matchMedia(`(max-device-width: 415px)`);
652
-
653
- const adjust = () => {
654
- if (window.innerWidth < h || media.matches){
655
- this.res.style.gridTemplateColumns = "1fr";
656
- } else {
657
- this.res.style.gridTemplateColumns = "1fr 1fr";
658
- }
659
- }
660
-
661
-
662
- if (window.innerWidth < h || media.matches){
663
- this.res.style.gridTemplateColumns = "1fr";
664
- } else {
665
- this.res.style.gridTemplateColumns = "1fr 1fr";
666
- }
667
-
668
-
669
- window.addEventListener("resize", adjust);
670
-
671
-
672
- return this; // :D
673
- return this;
674
- }
675
-
676
-
677
- render(el) {
678
- // console.log("BORDER:" + this.res.style.border);
679
- if (el){
680
- document.querySelector(el).appendChild(this.res);
681
- } else {
682
- return this.res;
683
- }
684
- }
685
- }
686
- export { CleanRow };