amotify 0.1.31 → 0.1.32

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 (95) hide show
  1. package/dist/@declaration/_.js +1 -1
  2. package/dist/@styles/componentClasses/_.css +68 -65
  3. package/dist/@styles/componentClasses/_.js +39 -39
  4. package/dist/@styles/index.css +68 -65
  5. package/dist/@styles/index.js +39 -39
  6. package/dist/@styles/init.css +1 -1
  7. package/dist/@styles/style.css +68 -65
  8. package/dist/@styles/style.js +39 -39
  9. package/dist/@styles/var.css +1 -1
  10. package/dist/@utils/GenerateClassName.js +470 -1
  11. package/dist/@utils/LaunchReactApp.js +78 -1
  12. package/dist/@utils/_.js +12 -1
  13. package/dist/@utils/collectForm.js +96 -1
  14. package/dist/@utils/color.js +103 -1
  15. package/dist/@utils/config.js +101 -1
  16. package/dist/@utils/fin.js +39 -1
  17. package/dist/@utils/getElement.js +13 -1
  18. package/dist/@utils/jsminEx.js +172 -1
  19. package/dist/@utils/pageTransit.js +33 -1
  20. package/dist/@utils/useRecycle.js +44 -1
  21. package/dist/@utils/useStore.js +54 -1
  22. package/dist/atoms/Box.js +20 -1
  23. package/dist/atoms/FAI.js +148 -1
  24. package/dist/atoms/Flex.js +34 -1
  25. package/dist/atoms/Grid.js +17 -1
  26. package/dist/atoms/Img.js +65 -1
  27. package/dist/atoms/Logo.js +359 -51
  28. package/dist/atoms/P.js +20 -1
  29. package/dist/atoms/Placeholder.js +44 -1
  30. package/dist/atoms/Span.js +20 -1
  31. package/dist/atoms/_.js +9 -1
  32. package/dist/chunk-JJ3PEWPN.js +60 -0
  33. package/dist/fn/Button.js +316 -1
  34. package/dist/fn/Cropper.js +1009 -1
  35. package/dist/fn/Effect/Fade.js +88 -1
  36. package/dist/fn/Effect/Pudding.js +22 -1
  37. package/dist/fn/Effect/Ripple.js +117 -3
  38. package/dist/fn/Effect/_.js +14 -1
  39. package/dist/fn/Input/AutoHeightText.js +112 -1
  40. package/dist/fn/Input/Checker.js +36 -1
  41. package/dist/fn/Input/Chips/Selector.js +472 -1
  42. package/dist/fn/Input/Chips/_.js +349 -1
  43. package/dist/fn/Input/Contenteditable.js +160 -1
  44. package/dist/fn/Input/DigitCharacters.js +275 -1
  45. package/dist/fn/Input/Filer.js +619 -1
  46. package/dist/fn/Input/Hidden.js +48 -1
  47. package/dist/fn/Input/List.js +450 -1
  48. package/dist/fn/Input/Parts.js +121 -1
  49. package/dist/fn/Input/Plain.js +12 -1
  50. package/dist/fn/Input/RichSelect.js +279 -1
  51. package/dist/fn/Input/Search.js +53 -1
  52. package/dist/fn/Input/Segmented.js +245 -1
  53. package/dist/fn/Input/Select.js +278 -1
  54. package/dist/fn/Input/Slider.js +538 -1
  55. package/dist/fn/Input/Switch.js +221 -1
  56. package/dist/fn/Input/Text.js +626 -1
  57. package/dist/fn/Input/TextArea.js +151 -1
  58. package/dist/fn/Input/Time/Picker.js +1457 -1
  59. package/dist/fn/Input/Time/_.js +867 -1
  60. package/dist/fn/Input/_.js +48 -1
  61. package/dist/fn/Input/core.js +626 -1
  62. package/dist/fn/Layout/PageNotFound.js +90 -1
  63. package/dist/fn/Layout/PageRouter.js +87 -1
  64. package/dist/fn/Layout/PageViewController.js +29 -1
  65. package/dist/fn/Layout/Plate.js +37 -1
  66. package/dist/fn/Layout/RootViewController.js +315 -1
  67. package/dist/fn/Layout/SwipeView.js +348 -1
  68. package/dist/fn/Layout/TabBar.js +72 -1
  69. package/dist/fn/Layout/_.js +22 -1
  70. package/dist/fn/Loader/_.js +104 -1
  71. package/dist/fn/Loader/corner.js +85 -1
  72. package/dist/fn/Loader/mini.js +125 -1
  73. package/dist/fn/Loader/top.js +73 -1
  74. package/dist/fn/Sheet.js +1101 -1
  75. package/dist/fn/Snackbar.js +216 -1
  76. package/dist/fn/Table/Data.js +974 -1
  77. package/dist/fn/Table/Drag.js +435 -1
  78. package/dist/fn/Table/Normal.js +136 -1
  79. package/dist/fn/Table/Parts.js +41 -1
  80. package/dist/fn/Table/Wrapper.js +60 -1
  81. package/dist/fn/Table/_.js +16 -1
  82. package/dist/fn/Table/cellStyling.js +51 -1
  83. package/dist/fn/Tooltips.js +58 -1
  84. package/dist/fn/_.js +10 -1
  85. package/dist/index.js +20 -1
  86. package/dist/mols/Accordion.js +152 -1
  87. package/dist/mols/Column.js +16 -1
  88. package/dist/mols/LinkifyText.js +42 -1
  89. package/dist/mols/List.js +42 -1
  90. package/dist/mols/Row.js +47 -1
  91. package/dist/mols/Text.js +67 -1
  92. package/dist/mols/_.js +6 -1
  93. package/dist/temps/_.js +1 -1
  94. package/dist/temps/designBook.js +3639 -20
  95. package/package.json +1 -1
@@ -1 +1,216 @@
1
- import{b as m,c,d as C}from"../chunk-VY3566IV.js";import{Fragment as O,jsx as o,jsxs as P}from"react/jsx-runtime";import{createElement as _}from"react";import{$$ as s,Config as S,useStore as p,$$fromRoot as w}from"../@utils/_";import{useState as f,useEffect as D}from"react";import x from"../atoms/Box";import y from"../atoms/Flex";import E from"../atoms/FAI";import R from"../mols/Row";import A from"./Button";import{SnackbarClasses as k}from"../@styles/componentClasses/_";const u={add:function(i){return p.get("Snackbar-"+S.get().sessionUID).add(i),this},remove:function(i){return p.get("Snackbar-"+S.get().sessionUID).remove(i),this},Wrapper:()=>o(B.Wrapper,{})},B={Cell:i=>{let b=i,{snackID:l,secondsToClose:n=10,componentID:g=s.uuid.gen(),children:d,customChildren:e}=b,r=C(b,["snackID","secondsToClose","componentID","children","customChildren"]),[t]=f(g),[a,h]=f(!1);D(()=>{let v=w('[data-component-id="'+t+'"]');setTimeout(()=>{v.addClass(k("FadeIn"))},10),p.set({key:"Snackbar-"+l,value:{remove:()=>{v.addClass(k("FadeOut"))}}})},[]),D(()=>{s.interval.clear("Snackbar-"+t),a||setTimeout(()=>{s.interval.standBy("Snackbar-"+t,n*1e3,()=>{a||u.remove(l)})},100)},[a]);let I=o(O,{});return e?I=o(e,{close:()=>{u.remove(l)}}):I=P(R.Separate,{verticalAlign:"top",children:[o(x,{padding:["1/4",0],flexSizing:0,children:s.is.function(d)?o(d,{}):d}),o(A.Button.Clear.R,{color:"layer",backgroundColor:"lcOpLow",fontColor:"white",ssSphere:2.5,onClick:()=>{u.remove(l)},children:o(E.Times,{})})]}),o(x,c(m({className:k("Cell"),opacity:"trans",width:1,padding:"2/3",marginBottom:1,borderRadius:"1.tone.primary",fontColor:"white",boxShadow:"1.remark",backgroundColor:"dark",transition:"middle",componentID:t,onMouseOver:()=>{h(!0)},onMouseOut:()=>{h(!1)}},r),{children:I}))},Wrapper:()=>{let[i,l]=f(s.uuid.gen()),[n,g]=f([]);p.set({key:"Snackbar-"+S.get().sessionUID,value:{add:e=>{e.snackID=e.snackID||s.uuid.gen();let r=n.findIndex(t=>t.snackID==e.snackID);if(r==-1)n.unshift(c(m({},e),{snackID:e.snackID}));else{let t=[...n];t[r]=c(m({},e),{snackID:e.snackID}),n=t}l(s.uuid.gen())},remove:e=>{let r=p.get("Snackbar-"+e);r&&r.remove&&(r.remove(),setTimeout(()=>{let t=n.findIndex(a=>a.snackID==e);if(t!=-1){let a=[...n];a.splice(t,1),g(a)}},210))}}});let d=n.map(e=>_(B.Cell,c(m({},e),{key:e.snackID})));return o(y,{className:["AMOTIFY_be",k("Wrapper")].join(" "),position:"fixed",right:0,bottom:0,paddingLeft:0,paddingRight:1,paddingBottom:"safeAreaBottom",verticalAlign:"bottom",children:d,overflow:"auto",UnderBreakPointStyles:{left:0,paddingLeft:1,width:"auto"}})}};export{u as Snackbar,u as default};
1
+ import {
2
+ __objRest,
3
+ __spreadProps,
4
+ __spreadValues
5
+ } from "../chunk-JJ3PEWPN.js";
6
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
7
+ import { createElement } from "react";
8
+ import {
9
+ $$,
10
+ Config,
11
+ useStore,
12
+ $$fromRoot
13
+ } from "../@utils/_";
14
+ import {
15
+ useState,
16
+ useEffect
17
+ } from "react";
18
+ import Box from "../atoms/Box";
19
+ import Flex from "../atoms/Flex";
20
+ import FAI from "../atoms/FAI";
21
+ import Row from "../mols/Row";
22
+ import Button from "./Button";
23
+ import { SnackbarClasses } from "../@styles/componentClasses/_";
24
+ const Snackbar = {
25
+ add: function(params) {
26
+ useStore.get("Snackbar-" + Config.get().sessionUID).add(params);
27
+ return this;
28
+ },
29
+ remove: function(val_componentID) {
30
+ useStore.get("Snackbar-" + Config.get().sessionUID).remove(val_componentID);
31
+ return this;
32
+ },
33
+ Wrapper: () => {
34
+ return /* @__PURE__ */ jsx(Comps.Wrapper, {});
35
+ }
36
+ };
37
+ const Comps = {
38
+ Cell: (props) => {
39
+ let _a = props, {
40
+ snackID,
41
+ secondsToClose = 10,
42
+ componentID = $$.uuid.gen(),
43
+ children: Children,
44
+ customChildren: CustomChildren
45
+ } = _a, others = __objRest(_a, [
46
+ "snackID",
47
+ "secondsToClose",
48
+ "componentID",
49
+ "children",
50
+ "customChildren"
51
+ ]);
52
+ let [val_componentID] = useState(componentID);
53
+ let [val_mouseOn, set_mouseOn] = useState(false);
54
+ useEffect(() => {
55
+ let Wrapper = $$fromRoot('[data-component-id="' + val_componentID + '"]');
56
+ setTimeout(() => {
57
+ Wrapper.addClass(SnackbarClasses("FadeIn"));
58
+ }, 10);
59
+ useStore.set({
60
+ key: "Snackbar-" + snackID,
61
+ value: {
62
+ remove: () => {
63
+ Wrapper.addClass(SnackbarClasses("FadeOut"));
64
+ }
65
+ }
66
+ });
67
+ }, []);
68
+ useEffect(() => {
69
+ $$.interval.clear("Snackbar-" + val_componentID);
70
+ if (!val_mouseOn) {
71
+ setTimeout(() => {
72
+ $$.interval.standBy(
73
+ "Snackbar-" + val_componentID,
74
+ secondsToClose * 1e3,
75
+ () => {
76
+ if (!val_mouseOn)
77
+ Snackbar.remove(snackID);
78
+ }
79
+ );
80
+ }, 100);
81
+ }
82
+ }, [val_mouseOn]);
83
+ let Content = /* @__PURE__ */ jsx(Fragment, {});
84
+ if (CustomChildren) {
85
+ Content = /* @__PURE__ */ jsx(
86
+ CustomChildren,
87
+ {
88
+ close: () => {
89
+ Snackbar.remove(snackID);
90
+ }
91
+ }
92
+ );
93
+ } else {
94
+ Content = /* @__PURE__ */ jsxs(
95
+ Row.Separate,
96
+ {
97
+ verticalAlign: "top",
98
+ children: [
99
+ /* @__PURE__ */ jsx(
100
+ Box,
101
+ {
102
+ padding: ["1/4", 0],
103
+ flexSizing: 0,
104
+ children: $$.is.function(Children) ? /* @__PURE__ */ jsx(Children, {}) : Children
105
+ }
106
+ ),
107
+ /* @__PURE__ */ jsx(
108
+ Button.Button.Clear.R,
109
+ {
110
+ color: "layer",
111
+ backgroundColor: "lcOpLow",
112
+ fontColor: "white",
113
+ ssSphere: 2.5,
114
+ onClick: () => {
115
+ Snackbar.remove(snackID);
116
+ },
117
+ children: /* @__PURE__ */ jsx(FAI.Times, {})
118
+ }
119
+ )
120
+ ]
121
+ }
122
+ );
123
+ }
124
+ return /* @__PURE__ */ jsx(
125
+ Box,
126
+ __spreadProps(__spreadValues({
127
+ className: SnackbarClasses("Cell"),
128
+ opacity: "trans",
129
+ width: 1,
130
+ padding: "2/3",
131
+ marginBottom: 1,
132
+ borderRadius: "1.tone.primary",
133
+ fontColor: "white",
134
+ boxShadow: "1.remark",
135
+ backgroundColor: "dark",
136
+ transition: "middle",
137
+ componentID: val_componentID,
138
+ onMouseOver: () => {
139
+ set_mouseOn(true);
140
+ },
141
+ onMouseOut: () => {
142
+ set_mouseOn(false);
143
+ }
144
+ }, others), {
145
+ children: Content
146
+ })
147
+ );
148
+ },
149
+ Wrapper: () => {
150
+ let [val_refresh, set_refresh] = useState($$.uuid.gen());
151
+ let [val_elements, set_elements] = useState([]);
152
+ useStore.set({
153
+ key: "Snackbar-" + Config.get().sessionUID,
154
+ value: {
155
+ add: (params) => {
156
+ params.snackID = params.snackID || $$.uuid.gen();
157
+ let findIndex = val_elements.findIndex((el) => el.snackID == params.snackID);
158
+ if (findIndex == -1) {
159
+ val_elements.unshift(__spreadProps(__spreadValues({}, params), {
160
+ snackID: params.snackID
161
+ }));
162
+ } else {
163
+ let newList = [...val_elements];
164
+ newList[findIndex] = __spreadProps(__spreadValues({}, params), {
165
+ snackID: params.snackID
166
+ });
167
+ val_elements = newList;
168
+ }
169
+ set_refresh($$.uuid.gen());
170
+ },
171
+ remove: (snackID) => {
172
+ let component = useStore.get("Snackbar-" + snackID);
173
+ if (component && component.remove) {
174
+ component.remove();
175
+ setTimeout(() => {
176
+ let findIndex = val_elements.findIndex((cell) => cell.snackID == snackID);
177
+ if (findIndex != -1) {
178
+ let newList = [...val_elements];
179
+ newList.splice(findIndex, 1);
180
+ set_elements(newList);
181
+ }
182
+ }, 210);
183
+ }
184
+ }
185
+ }
186
+ });
187
+ let Snackbars = val_elements.map((el) => /* @__PURE__ */ createElement(Comps.Cell, __spreadProps(__spreadValues({}, el), { key: el.snackID })));
188
+ return /* @__PURE__ */ jsx(
189
+ Flex,
190
+ {
191
+ className: [
192
+ "AMOTIFY_be",
193
+ SnackbarClasses("Wrapper")
194
+ ].join(" "),
195
+ position: "fixed",
196
+ right: 0,
197
+ bottom: 0,
198
+ paddingLeft: 0,
199
+ paddingRight: 1,
200
+ paddingBottom: "safeAreaBottom",
201
+ verticalAlign: "bottom",
202
+ children: Snackbars,
203
+ overflow: "auto",
204
+ UnderBreakPointStyles: {
205
+ left: 0,
206
+ paddingLeft: 1,
207
+ width: "auto"
208
+ }
209
+ }
210
+ );
211
+ }
212
+ };
213
+ export {
214
+ Snackbar,
215
+ Snackbar as default
216
+ };