ziko 0.0.5 → 0.0.7

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 (236) hide show
  1. package/README.md +171 -182
  2. package/dist/ziko.cjs +10022 -9853
  3. package/dist/ziko.js +10023 -9854
  4. package/dist/ziko.min.js +2 -2
  5. package/dist/ziko.mjs +10021 -9853
  6. package/package.json +12 -4
  7. package/starter/bin/index.js +11 -0
  8. package/wrapper/react/README.md +26 -0
  9. package/wrapper/react/index.jsx +7 -1
  10. package/wrapper/svelte/ZikoUI.svelte +15 -0
  11. package/wrapper/vue/ZikoUI.vue +8 -2
  12. package/core/App/Accessibility/index.js +0 -0
  13. package/core/App/Globals/__Target__.js +0 -3
  14. package/core/App/Globals/__UI__.js +0 -38
  15. package/core/App/Globals/__init__.js +0 -8
  16. package/core/App/Globals/index.js +0 -18
  17. package/core/App/Router/index.js +0 -40
  18. package/core/App/Seo/index.js +0 -43
  19. package/core/App/Themes/dark.js +0 -885
  20. package/core/App/Themes/index.js +0 -11
  21. package/core/App/Themes/light.js +0 -255
  22. package/core/App/app.js +0 -46
  23. package/core/App/index.js +0 -12
  24. package/core/Data/Api/fetchdom.js +0 -14
  25. package/core/Data/Api/index.js +0 -4
  26. package/core/Data/Api/preload.js +0 -11
  27. package/core/Data/Converter/canvas.js +0 -25
  28. package/core/Data/Converter/csv.js +0 -33
  29. package/core/Data/Converter/index.js +0 -25
  30. package/core/Data/Converter/json.js +0 -80
  31. package/core/Data/Converter/markdown.js +0 -83
  32. package/core/Data/Converter/svg.js +0 -11
  33. package/core/Data/Parser/markdown.js +0 -0
  34. package/core/Data/Parser/xml.js +0 -47
  35. package/core/Data/Strings/index.js +0 -26
  36. package/core/Data/decorators.js +0 -0
  37. package/core/Data/index.js +0 -64
  38. package/core/Graphics/Canvas/Elements/Basic/arc.js +0 -43
  39. package/core/Graphics/Canvas/Elements/Basic/image.js +0 -0
  40. package/core/Graphics/Canvas/Elements/Basic/line.js +0 -26
  41. package/core/Graphics/Canvas/Elements/Basic/path.js +0 -0
  42. package/core/Graphics/Canvas/Elements/Basic/points.js +0 -48
  43. package/core/Graphics/Canvas/Elements/Basic/polygon.js +0 -7
  44. package/core/Graphics/Canvas/Elements/Basic/polyline.js +0 -0
  45. package/core/Graphics/Canvas/Elements/Basic/rect.js +0 -46
  46. package/core/Graphics/Canvas/Elements/Basic/text.js +0 -0
  47. package/core/Graphics/Canvas/Elements/Chart/histogram.js +0 -0
  48. package/core/Graphics/Canvas/Elements/Chart/plot.js +0 -0
  49. package/core/Graphics/Canvas/Elements/Chart/scatter.js +0 -2
  50. package/core/Graphics/Canvas/Elements/Chart/stem.js +0 -0
  51. package/core/Graphics/Canvas/Elements/Element.js +0 -115
  52. package/core/Graphics/Canvas/Elements/Groupe.js +0 -0
  53. package/core/Graphics/Canvas/Elements/grid.js +0 -0
  54. package/core/Graphics/Canvas/Elements/index.js +0 -13
  55. package/core/Graphics/Canvas/Filter/index.js +0 -0
  56. package/core/Graphics/Canvas/Paint/index.js +0 -0
  57. package/core/Graphics/Canvas/Utils/color.js +0 -8
  58. package/core/Graphics/Canvas/Utils/floodFill.js +0 -58
  59. package/core/Graphics/Canvas/_canvas_offscreen +0 -0
  60. package/core/Graphics/Canvas/canvas.js +0 -189
  61. package/core/Graphics/Canvas/index.js +0 -15
  62. package/core/Graphics/Svg/Elements/ZikoSvgElement.js +0 -28
  63. package/core/Graphics/Svg/Elements/circle.js +0 -34
  64. package/core/Graphics/Svg/Elements/ellipse.js +0 -29
  65. package/core/Graphics/Svg/Elements/foreignObject.js +0 -46
  66. package/core/Graphics/Svg/Elements/grid.js +0 -9
  67. package/core/Graphics/Svg/Elements/groupe.js +0 -29
  68. package/core/Graphics/Svg/Elements/image.js +0 -33
  69. package/core/Graphics/Svg/Elements/line.js +0 -29
  70. package/core/Graphics/Svg/Elements/path.js +0 -59
  71. package/core/Graphics/Svg/Elements/polygon.js +0 -31
  72. package/core/Graphics/Svg/Elements/polyline.js +0 -4
  73. package/core/Graphics/Svg/Elements/rect.js +0 -43
  74. package/core/Graphics/Svg/Elements/text.js +0 -26
  75. package/core/Graphics/Svg/index.js +0 -1
  76. package/core/Graphics/Svg/svg.js +0 -117
  77. package/core/Graphics/index.js +0 -61
  78. package/core/Math/Calculus/Special Functions/bessel.js +0 -31
  79. package/core/Math/Calculus/Special Functions/beta.js +0 -38
  80. package/core/Math/Calculus/Special Functions/gamma.js +0 -30
  81. package/core/Math/Calculus/Special Functions/index.js +0 -4
  82. package/core/Math/Calculus/index.js +0 -1
  83. package/core/Math/Complex/Fractals/julia.js +0 -0
  84. package/core/Math/Complex/index.js +0 -191
  85. package/core/Math/Discret/Combinaison/index.js +0 -34
  86. package/core/Math/Discret/Conversion/index.js +0 -86
  87. package/core/Math/Discret/Logic/index.js +0 -46
  88. package/core/Math/Discret/Permutation/index.js +0 -31
  89. package/core/Math/Discret/Set/index.js +0 -2
  90. package/core/Math/Discret/Set/powerSet.js +0 -15
  91. package/core/Math/Discret/Set/subSet.js +0 -10
  92. package/core/Math/Discret/index.js +0 -23
  93. package/core/Math/Functions/index.js +0 -182
  94. package/core/Math/Matrix/Decomposition.js +0 -90
  95. package/core/Math/Matrix/LinearSystem.js +0 -10
  96. package/core/Math/Matrix/Matrix.js +0 -712
  97. package/core/Math/Matrix/index.js +0 -3
  98. package/core/Math/Numeric/index.js +0 -0
  99. package/core/Math/Random/index.js +0 -173
  100. package/core/Math/Signal/__np.py.txt +0 -40
  101. package/core/Math/Signal/conv.js +0 -175
  102. package/core/Math/Signal/fft.js +0 -55
  103. package/core/Math/Signal/filter.js +0 -39
  104. package/core/Math/Signal/functions.js +0 -146
  105. package/core/Math/Signal/index.js +0 -110
  106. package/core/Math/Statistics/Functions/index.js +0 -100
  107. package/core/Math/Statistics/index.js +0 -16
  108. package/core/Math/Utils/arithmetic.js +0 -139
  109. package/core/Math/Utils/checkers.js +0 -11
  110. package/core/Math/Utils/comparaison.js +0 -1
  111. package/core/Math/Utils/conversions.js +0 -7
  112. package/core/Math/Utils/discret.js +0 -28
  113. package/core/Math/Utils/index.js +0 -102
  114. package/core/Math/Utils/mapfun.js +0 -43
  115. package/core/Math/absract.js +0 -1
  116. package/core/Math/const.js +0 -3
  117. package/core/Math/index.js +0 -193
  118. package/core/Reactivity/Events/Global/Click.js +0 -56
  119. package/core/Reactivity/Events/Global/Clipboard.js +0 -84
  120. package/core/Reactivity/Events/Global/CustomEvent.js +0 -53
  121. package/core/Reactivity/Events/Global/Drag.js +0 -137
  122. package/core/Reactivity/Events/Global/Focus.js +0 -56
  123. package/core/Reactivity/Events/Global/Key.js +0 -104
  124. package/core/Reactivity/Events/Global/Mouse.js +0 -230
  125. package/core/Reactivity/Events/Global/Pointer.js +0 -214
  126. package/core/Reactivity/Events/Global/Touch.js +0 -0
  127. package/core/Reactivity/Events/Global/Wheel.js +0 -44
  128. package/core/Reactivity/Events/Partiel/Hash.js +0 -44
  129. package/core/Reactivity/Events/Partiel/Input.js +0 -59
  130. package/core/Reactivity/Events/Partiel/MediaEvent.js +0 -1
  131. package/core/Reactivity/Events/ZikoEvent.js +0 -91
  132. package/core/Reactivity/Events/index.js +0 -60
  133. package/core/Reactivity/Observer/index.js +0 -3
  134. package/core/Reactivity/Observer/intersection.js +0 -40
  135. package/core/Reactivity/Observer/mutation.js +0 -90
  136. package/core/Reactivity/Observer/resize.js +0 -47
  137. package/core/Reactivity/Use/Contexte/index.js +0 -1
  138. package/core/Reactivity/Use/Contexte/useSuccesifKeys.js +0 -14
  139. package/core/Reactivity/Use/Decorators/index.js +0 -4
  140. package/core/Reactivity/Use/Interactions/index.js +0 -4
  141. package/core/Reactivity/Use/Interactions/useBluetooth.js +0 -48
  142. package/core/Reactivity/Use/Interactions/useChannel.js +0 -50
  143. package/core/Reactivity/Use/Interactions/useEventEmmiter.js +0 -64
  144. package/core/Reactivity/Use/Interactions/useSerial.js +0 -0
  145. package/core/Reactivity/Use/Interactions/useThread.js +0 -44
  146. package/core/Reactivity/Use/Interactions/useUsb.js +0 -0
  147. package/core/Reactivity/Use/Sensors/index.js +0 -2
  148. package/core/Reactivity/Use/Sensors/useBattery.js +0 -36
  149. package/core/Reactivity/Use/Sensors/useCamera.js +0 -0
  150. package/core/Reactivity/Use/Sensors/useGeolocation.js +0 -17
  151. package/core/Reactivity/Use/Sensors/useMicro.js +0 -0
  152. package/core/Reactivity/Use/Sensors/useOrientation.js +0 -0
  153. package/core/Reactivity/Use/Storage/index.js +0 -1
  154. package/core/Reactivity/Use/Storage/useCookie.js +0 -0
  155. package/core/Reactivity/Use/Storage/useIndexedDb.js +0 -0
  156. package/core/Reactivity/Use/Storage/useStorage.js +0 -74
  157. package/core/Reactivity/Use/UI/index.js +0 -4
  158. package/core/Reactivity/Use/UI/useCssLink.js +0 -0
  159. package/core/Reactivity/Use/UI/useCssText.js +0 -21
  160. package/core/Reactivity/Use/UI/useFavIcon.js +0 -38
  161. package/core/Reactivity/Use/UI/useLinearGradient.js +0 -0
  162. package/core/Reactivity/Use/UI/useMediaQuery.js +0 -1
  163. package/core/Reactivity/Use/UI/useRadialGradient.js +0 -0
  164. package/core/Reactivity/Use/UI/useStyle.js +0 -54
  165. package/core/Reactivity/Use/UI/useTheme.js +0 -62
  166. package/core/Reactivity/Use/UI/useTitle.js +0 -30
  167. package/core/Reactivity/Use/index.js +0 -82
  168. package/core/Reactivity/Use/todo.md +0 -26
  169. package/core/Reactivity/index.js +0 -3
  170. package/core/Time/animation.js +0 -76
  171. package/core/Time/index.js +0 -54
  172. package/core/Time/loop.js +0 -83
  173. package/core/Time/utils/decorators.js +0 -17
  174. package/core/Time/utils/ease.js +0 -144
  175. package/core/Time/utils/index.js +0 -18
  176. package/core/Time/utils/performance.js +0 -16
  177. package/core/Time/utils/ui.js +0 -26
  178. package/core/UI/CustomElement/Elements/Accordion/index.js +0 -62
  179. package/core/UI/CustomElement/Elements/Carousel/index.js +0 -47
  180. package/core/UI/CustomElement/Elements/CodeNote/CodeCell.js +0 -176
  181. package/core/UI/CustomElement/Elements/CodeNote/CodeNote.js +0 -69
  182. package/core/UI/CustomElement/Elements/CodeNote/SubElements.js +0 -64
  183. package/core/UI/CustomElement/Elements/CodeNote/index.js +0 -2
  184. package/core/UI/CustomElement/Elements/Columns.js +0 -1
  185. package/core/UI/CustomElement/Elements/FAB.js +0 -0
  186. package/core/UI/CustomElement/Elements/Menu.js +0 -0
  187. package/core/UI/CustomElement/Elements/Notification.js +0 -0
  188. package/core/UI/CustomElement/Elements/Popover.js +0 -0
  189. package/core/UI/CustomElement/Elements/Popup.js +0 -0
  190. package/core/UI/CustomElement/Elements/Swipper.js +0 -4
  191. package/core/UI/CustomElement/Elements/Tabs/index.js +0 -111
  192. package/core/UI/CustomElement/Elements/Timeline.js +0 -0
  193. package/core/UI/CustomElement/Elements/Toast.js +0 -0
  194. package/core/UI/CustomElement/Elements/Treeview.js +0 -0
  195. package/core/UI/CustomElement/Elements/index.js +0 -4
  196. package/core/UI/CustomElement/Flex.js +0 -97
  197. package/core/UI/CustomElement/Grid.js +0 -30
  198. package/core/UI/CustomElement/index.js +0 -3
  199. package/core/UI/Embaded/index.js +0 -1
  200. package/core/UI/Inputs/Primitives/btn.js +0 -30
  201. package/core/UI/Inputs/Primitives/elements.js +0 -28
  202. package/core/UI/Inputs/Primitives/inputs.js +0 -324
  203. package/core/UI/Inputs/Primitives/select.js +0 -14
  204. package/core/UI/Inputs/Primitives/textarea.js +0 -15
  205. package/core/UI/Inputs/camera.js +0 -23
  206. package/core/UI/Inputs/index.js +0 -20
  207. package/core/UI/List/elements.js +0 -0
  208. package/core/UI/List/index.js +0 -127
  209. package/core/UI/Media/Audio/index.js +0 -38
  210. package/core/UI/Media/Image/figure.js +0 -16
  211. package/core/UI/Media/Image/image.js +0 -33
  212. package/core/UI/Media/Image/index.js +0 -2
  213. package/core/UI/Media/Video/index.js +0 -49
  214. package/core/UI/Media/index.js +0 -3
  215. package/core/UI/Misc/index.js +0 -45
  216. package/core/UI/Semantic/index.js +0 -61
  217. package/core/UI/Style/index.js +0 -499
  218. package/core/UI/Table/elements.js +0 -94
  219. package/core/UI/Table/index.js +0 -3
  220. package/core/UI/Table/table.js +0 -112
  221. package/core/UI/Table/utils.js +0 -12
  222. package/core/UI/Text/heading.js +0 -34
  223. package/core/UI/Text/index.js +0 -3
  224. package/core/UI/Text/p.js +0 -36
  225. package/core/UI/Text/pre.js +0 -0
  226. package/core/UI/Text/text.js +0 -65
  227. package/core/UI/Utils/index.js +0 -70
  228. package/core/UI/ZikoUIElement.js +0 -503
  229. package/core/UI/index.js +0 -154
  230. package/core/__proto__/Array.js +0 -74
  231. package/core/__proto__/Function.js +0 -0
  232. package/core/__proto__/Number.js +0 -76
  233. package/core/__proto__/Object.js +0 -0
  234. package/core/__proto__/String.js +0 -0
  235. package/core/index.js +0 -72
  236. package/wrapper/react/readme.md +0 -19
@@ -1,12 +0,0 @@
1
- import { td,tr } from "./elements.js";
2
- export const MatrixToTableUI=matrix=>{
3
- var Tr = new Array(matrix.rows).fill(null).map(() => tr());
4
- var Td = matrix.arr.map((n) => n.map(() => null));
5
- for (let i = 0; i < Td.length; i++) {
6
- for (let j = 0; j < Td[0].length; j++) {
7
- Td[i][j] = td(matrix.arr[i][j]);
8
- Tr[i].append(Td[i][j]);
9
- }
10
- }
11
- return Tr
12
- }
@@ -1,34 +0,0 @@
1
- import ZikoUIElement from "../ZikoUIElement.js";
2
- class ZikoUIHeading extends ZikoUIElement {
3
- constructor(type = 1, value = "") {
4
- super(`h${type}`,`h${type}`);
5
- this.element = document.createElement("h" + type);
6
- this.element.textContent = value;
7
- }
8
- get value() {
9
- return this.element.innerText;
10
- }
11
- setValue(text = "") {
12
- this.element.innerText = text;
13
- return;
14
- }
15
- addValue(text = "") {
16
- this.element.innerText += text;
17
- return this;
18
- }
19
- }
20
- const h1=(text="")=>new ZikoUIHeading(1, text);
21
- const h2=(text="")=>new ZikoUIHeading(2, text);
22
- const h3=(text="")=>new ZikoUIHeading(3, text);
23
- const h4=(text="")=>new ZikoUIHeading(4, text);
24
- const h5=(text="")=>new ZikoUIHeading(5, text);
25
- const h6=(text="")=>new ZikoUIHeading(6, text);
26
- export{
27
- h1,
28
- h2,
29
- h3,
30
- h4,
31
- h5,
32
- h6,
33
- ZikoUIHeading
34
- }
@@ -1,3 +0,0 @@
1
- export { text } from "./text.js";
2
- export {p} from "./p.js";
3
- export {h1,h2,h3,h4,h5,h6} from "./heading.js";
package/core/UI/Text/p.js DELETED
@@ -1,36 +0,0 @@
1
- import ZikoUIElement from "../ZikoUIElement.js";
2
- import {Complex} from "../../Math/Complex/index.js"
3
- import { text } from "./text.js";
4
- class ZikoUIParagraphe extends ZikoUIElement {
5
- constructor(...value) {
6
- super("p","p");
7
- this.addValue(...value);
8
- this.style({margin:0,padding:0});
9
- }
10
- addValue(...value) {
11
- for (let i = 0; i < value.length; i++) {
12
- if (typeof value[i] == "string" || typeof value[i] == "number") {
13
- this.element.appendChild(document.createTextNode(value[i]));
14
- this.element.appendChild(document.createElement("br"));
15
- } else if (value[i] instanceof ZikoUIElement)
16
- this.element.appendChild(value[i].element);
17
- else if (value[i] instanceof Complex)
18
- text(value.a + " + " + value.b + "i");
19
- }
20
- return this;
21
- }
22
- clear() {
23
- this.element.childNodes.forEach((e) => e.remove());
24
- return this;
25
- }
26
- setValue(...value) {
27
- this.clear();
28
- this.addValue(...value);
29
- return this;
30
- }
31
- }
32
- const p = (...ZikoUIElement) => new ZikoUIParagraphe().append(...ZikoUIElement);
33
- export {
34
- p,
35
- ZikoUIParagraphe
36
- }
File without changes
@@ -1,65 +0,0 @@
1
- import ZikoUIElement from "../ZikoUIElement.js";
2
- import {Complex} from "../../Math/Complex/index.js";
3
- import { __UI__ } from "../../App/Globals/__UI__.js";
4
- class ZikoUIText extends ZikoUIElement {
5
- constructor(...value) {
6
- super("span","text");
7
- this.element = document.createElement("span");
8
- this.text = "";
9
- this.addValue(...value);
10
- this.st.display("inline-block");
11
- }
12
- clear() {
13
- this.element.textContent = "";
14
- return this;
15
- }
16
- get value() {
17
- return this.element.textContent;
18
- }
19
- setValue(value = "", add = false) {
20
- if (["string", "number"].includes(typeof value)) {
21
- this.text = "" + value;
22
- if (this.text.includes("\n"))
23
- this.text = this.text
24
- .split("\n")
25
- .map((n) => "<span>".concat(n, "</span></br>"))
26
- .join("");
27
- }
28
- if (value instanceof Complex) this.text = "" + value.UI();
29
- /*
30
- else if (value instanceof Ziko.Math.Matrix) {
31
- let string = "[";
32
- for (let j = 0; j < value.arr.length; j++)
33
- string +=
34
- (j != 0 ? " " : "") +
35
- `[${value.arr[j].map((n) => " " + n.toString() + " ")}],</br>`;
36
- string = string.substring(0, string.length - 6) + "]";
37
- this.text = "" + string;
38
- }
39
- */
40
- //else console.error("not supported yet")
41
- if (add) this.element.innerHTML += this.text;
42
- else this.element.innerHTML = this.text;
43
- if (value instanceof Array || value instanceof Set) {
44
- if (value instanceof Set) value = [...value];
45
- this.addValue(...value);
46
- }
47
- }
48
- addValue(...value) {
49
- value.map((n) => {
50
- this.setValue(" ", true);
51
- this.setValue(n, true);
52
- });
53
- return this;
54
- }
55
- toggleValues(...values) {
56
- values = values.map((n) => "" + n);
57
- let index = values.indexOf("" + this.value);
58
- if (index != -1 && index != values.length - 1)
59
- this.setValue(values[index + 1]);
60
- else this.setValue(values[0]);
61
- return this;
62
- }
63
- }
64
- const text = (...value) => new ZikoUIText(...value)
65
- export {text}
@@ -1,70 +0,0 @@
1
- import ZikoUIElement from "../ZikoUIElement.js";
2
- const Id = (a) => document.getElementById(a);
3
- const Class = (a) => [...document.getElementsByClassName(a)];
4
- const $=(...selector)=>{
5
- var ele=[]
6
- for(let i=0;i<selector.length;i++){
7
- if(typeof selector[i]=="string")ele.push(...document.querySelectorAll(selector[i]));
8
- if(selector[i] instanceof ZikoUIElement)ele.push(selector[i].element)
9
- }
10
- return ele.length===1?ele[0]:ele;
11
- }
12
- const addSuffixeToNumber=(value,suffixe="px")=>{
13
- if(typeof value === "number") value+=suffixe;
14
- if(value instanceof Array)value=value.map(n=>typeof n==="number"?n+=suffixe:n).join(" ");
15
- return value;
16
- }
17
- const style = (el, styles) => {if(el)Object.assign(el.style, styles)};
18
-
19
- function script(src) {
20
- const Script = document.createElement("script");
21
- Script.setAttribute("src", src);
22
- document.head.appendChild(Script);
23
- }
24
- function linkStyle(href) {
25
- const link = document.createElement("link");
26
- link.setAttribute("rel", "stylesheet");
27
- link.setAttribute("href", href);
28
- document.head.appendChild(link);
29
- }
30
- const CloneElement = (UIElement) => {
31
- var clone = new UIElement.__proto__.constructor()
32
- //waitForUIElm(UIElement).then(e=>console.log(e)).then(()=>clone = new UIElement.__proto__.constructor())
33
- //let a = new UIElement.__proto__.constructor()
34
- return clone;
35
- };
36
- const cloneUI=UIElement=>{
37
- return Object.assign(Object.create(Object.getPrototypeOf(UIElement)),UIElement)
38
- }
39
- function isPrimitive(value) {
40
- return typeof value !== 'object' && typeof value !== 'function' || value === null;
41
- }
42
- const waitElm=(UIElement)=>{
43
- return new Promise(resolve => {
44
- if (UIElement) {
45
- return resolve(UIElement);
46
- }
47
- const observer = new MutationObserver(() => {
48
- if (UIElement) {
49
- resolve(UIElement);
50
- observer.disconnect();
51
- }
52
- });
53
- observer.observe(document.body, {
54
- childList: true,
55
- subtree: true
56
- });
57
- });
58
- }
59
- export{
60
- Id,
61
- Class,
62
- style,
63
- script,
64
- linkStyle,
65
- CloneElement,
66
- cloneUI,
67
- isPrimitive,
68
- addSuffixeToNumber,
69
- waitElm
70
- }