amotify 0.1.54 → 0.1.56

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.
@@ -1,12 +1,12 @@
1
1
  /**
2
2
  * @license amotify
3
- * amotify 0.1.54
3
+ * amotify 0.1.55
4
4
  * https://mingoo.co.jp/
5
5
 
6
6
  * Copyright (c) mingoo, LLC.
7
7
  * Released under the MIT license
8
8
 
9
- * Latest updated at: 2024/7/16
9
+ * Latest updated at: 2024/7/22
10
10
  */
11
11
 
12
12
  /* esbuild-sass-plugin:css-chunk:src/@styles/componentClasses/a_img.module.scss */
@@ -1,12 +1,12 @@
1
1
  /**
2
2
  * @license amotify
3
- * amotify 0.1.54
3
+ * amotify 0.1.55
4
4
  * https://mingoo.co.jp/
5
5
 
6
6
  * Copyright (c) mingoo, LLC.
7
7
  * Released under the MIT license
8
8
 
9
- * Latest updated at: 2024/7/16
9
+ * Latest updated at: 2024/7/22
10
10
  */
11
11
 
12
12
  /* esbuild-sass-plugin:css-chunk:src/@styles/componentClasses/a_img.module.scss */
@@ -1,12 +1,12 @@
1
1
  /**
2
2
  * @license amotify
3
- * amotify 0.1.54
3
+ * amotify 0.1.55
4
4
  * https://mingoo.co.jp/
5
5
 
6
6
  * Copyright (c) mingoo, LLC.
7
7
  * Released under the MIT license
8
8
 
9
- * Latest updated at: 2024/7/16
9
+ * Latest updated at: 2024/7/22
10
10
  */
11
11
 
12
12
  /* src/@styles/init.scss */
@@ -1,12 +1,12 @@
1
1
  /**
2
2
  * @license amotify
3
- * amotify 0.1.54
3
+ * amotify 0.1.55
4
4
  * https://mingoo.co.jp/
5
5
 
6
6
  * Copyright (c) mingoo, LLC.
7
7
  * Released under the MIT license
8
8
 
9
- * Latest updated at: 2024/7/16
9
+ * Latest updated at: 2024/7/22
10
10
  */
11
11
 
12
12
  /* src/@styles/@app.scss */
@@ -1,12 +1,12 @@
1
1
  /**
2
2
  * @license amotify
3
- * amotify 0.1.54
3
+ * amotify 0.1.55
4
4
  * https://mingoo.co.jp/
5
5
 
6
6
  * Copyright (c) mingoo, LLC.
7
7
  * Released under the MIT license
8
8
 
9
- * Latest updated at: 2024/7/16
9
+ * Latest updated at: 2024/7/22
10
10
  */
11
11
 
12
12
  /* src/@styles/var.scss */
@@ -1 +1 @@
1
- import{b as i,c as t}from"../chunk-VY3566IV.js";import{$$ as s}from".";import{useRecycle as c}from"./useRecycle";import{ColorObjects as h,SetThemeColorTag as u}from"./color";const f=s.uuid.gen(),n=window.navigator.userAgent.toLowerCase(),a=n.indexOf("windows nt")!==-1?"windows":n.indexOf("android")!==-1?"android":n.indexOf("iphone")!==-1?"iPhone":n.indexOf("ipad")>-1||n.indexOf("macintosh")>-1&&"ontouchend"in document?"iPad":n.indexOf("mac os x")!==-1?"macOSX":"undefined",p=n.indexOf("msie")!==-1||n.indexOf("trident")!==-1?"ie":n.indexOf("edge")!==-1?"edge":n.indexOf("chrome")!==-1?"chrome":n.indexOf("safari")!==-1?"safari":n.indexOf("firefox")!==-1?"firefox":n.indexOf("opera")!==-1||n.indexOf("opr")!==-1?"opera":"undefined";let m={sessionUID:f,appRoot:document.body,darkMode:"light",themeColor:"comun",roundness:2,isSystemDarkmode:()=>window.matchMedia("(prefers-color-scheme: dark)").matches==!0,deviceIs:a,browserIs:p,isPhone:["Android","iPhone"].includes(a),isTouchDevice:window.ontouchstart!==void 0&&0<navigator.maxTouchPoints,isIOS:["iPhone","iPad"].includes(a),screen:{breakpoint:834,phonepoint:690,viewHeight:window.innerHeight,viewWidth:window.innerWidth,isBreakpoint:(e=834)=>window.innerWidth<=e,isPhonepoint:(e=690)=>window.innerWidth<=e}};const o={get:()=>m,set:e=>{m=i(i({},m),e)},update:{appRoot:e=>{o.set(t(i({},o.get()),{appRoot:e}))},themeColor:e=>{if(h.find(d=>d.key==e)||(e="comun"),e==o.get().themeColor)return;o.set(t(i({},o.get()),{themeColor:e}));let r=s(document.body);r.removeClass(r.findClass(/^bdsTC/)).addClass("bdsTC_"+e).callback(()=>{u()}),o.restart()},darkMode:e=>{if(["light","dark","dim","auto"].includes(e)||(e="light"),e==o.get().darkMode)return;let r=e=="auto"?o.get().isSystemDarkmode()?"dark":"light":e;o.set(t(i({},o.get()),{darkMode:r}));let d=s(document.body);d.removeClass(d.findClass(/^bdsDM/)).addClass("bdsDM_"+r),o.restart()},roundness:e=>{e>=0&&e<=5||(e=2),e!=o.get().roundness&&(o.set(t(i({},o.get()),{roundness:e})),o.restart())},screen:e=>{o.get().screen=i(i({},o.get().screen),e)}},restart:()=>{c.do("RootViewController_"+o.get().sessionUID)}};export{o as Config,o as default};
1
+ import{b as i,c as t}from"../chunk-VY3566IV.js";import{$$ as d}from".";import{useRecycle as c}from"./useRecycle";import{ColorObjects as l,SetThemeColorTag as h}from"./color";const u=d.uuid.gen(),n=global.navigator.userAgent.toLowerCase(),a=n.indexOf("windows nt")!==-1?"windows":n.indexOf("android")!==-1?"android":n.indexOf("iphone")!==-1?"iPhone":n.indexOf("ipad")>-1||n.indexOf("macintosh")>-1&&"ontouchend"in document?"iPad":n.indexOf("mac os x")!==-1?"macOSX":"undefined",f=n.indexOf("msie")!==-1||n.indexOf("trident")!==-1?"ie":n.indexOf("edge")!==-1?"edge":n.indexOf("chrome")!==-1?"chrome":n.indexOf("safari")!==-1?"safari":n.indexOf("firefox")!==-1?"firefox":n.indexOf("opera")!==-1||n.indexOf("opr")!==-1?"opera":"undefined";let m={sessionUID:u,appRoot:document.body,darkMode:"light",themeColor:"comun",roundness:2,isSystemDarkmode:()=>global.matchMedia("(prefers-color-scheme: dark)").matches==!0,deviceIs:a,browserIs:f,isPhone:["Android","iPhone"].includes(a),isTouchDevice:global.ontouchstart!==void 0&&0<navigator.maxTouchPoints,isIOS:["iPhone","iPad"].includes(a),screen:{breakpoint:834,phonepoint:690,viewHeight:global.innerHeight,viewWidth:global.innerWidth,isBreakpoint:(e=834)=>global.innerWidth<=e,isPhonepoint:(e=690)=>global.innerWidth<=e}};const o={get:()=>m,set:e=>{m=i(i({},m),e)},update:{appRoot:e=>{o.set(t(i({},o.get()),{appRoot:e}))},themeColor:e=>{if(l.find(s=>s.key==e)||(e="comun"),e==o.get().themeColor)return;o.set(t(i({},o.get()),{themeColor:e}));let r=d(document.body);r.removeClass(r.findClass(/^bdsTC/)).addClass("bdsTC_"+e).callback(()=>{h()}),o.restart()},darkMode:e=>{if(["light","dark","dim","auto"].includes(e)||(e="light"),e==o.get().darkMode)return;let r=e=="auto"?o.get().isSystemDarkmode()?"dark":"light":e;o.set(t(i({},o.get()),{darkMode:r}));let s=d(document.body);s.removeClass(s.findClass(/^bdsDM/)).addClass("bdsDM_"+r),o.restart()},roundness:e=>{e>=0&&e<=5||(e=2),e!=o.get().roundness&&(o.set(t(i({},o.get()),{roundness:e})),o.restart())},screen:e=>{o.get().screen=i(i({},o.get().screen),e)}},restart:()=>{c.do("RootViewController_"+o.get().sessionUID)}};export{o as Config,o as default};
@@ -1 +1 @@
1
- import{$$ as o,Config as i,SetThemeColorTag as l}from".";o(document.body).addClass(["usrDevice_"+i.get().deviceIs,"bdsDM_"+i.get().darkMode,"bdsTC_"+i.get().themeColor]),o(window).addEvent({eventType:"load",callback:()=>{let e=document.body.style,t=o(document.body),r=Number(t.getStyleProperty("--topNavHeight").removeLetters()||0),n=Number(t.getStyleProperty("--footerNavHeight").removeLetters()||0),d=window.innerHeight-r-n;e.setProperty("--viewHeight",window.innerHeight+"px"),e.setProperty("--contentHeight",d+"px")}}).addEvent({eventType:"resize",eventID:"getDeviceInfo",callback:()=>{i.update.screen({viewHeight:window.innerHeight,viewWidth:window.innerWidth});let e=o(document.body),t=window.innerHeight,r=Number(e.getStyleProperty("--topNavHeight").removeLetters()),n=Number(e.getStyleProperty("--footerNavHeight").removeLetters()),g=t-r-n;e.setStyleProperty("--viewHeight",t+"px").setStyleProperty("--sideNavHeight",g+"px").setStyleProperty("--contentHeight",g+"px")}}),l();
1
+ import{$$ as o,Config as r,SetThemeColorTag as a}from".";o(document.body).addClass(["usrDevice_"+r.get().deviceIs,"bdsDM_"+r.get().darkMode,"bdsTC_"+r.get().themeColor]),o(global).addEvent({eventType:"load",callback:()=>{let e=document.body.style,t=o(document.body),i=Number(t.getStyleProperty("--topNavHeight").removeLetters()||0),l=Number(t.getStyleProperty("--footerNavHeight").removeLetters()||0),n=global.innerHeight-i-l;e.setProperty("--viewHeight",global.innerHeight+"px"),e.setProperty("--contentHeight",n+"px")}}).addEvent({eventType:"resize",eventID:"getDeviceInfo",callback:()=>{r.update.screen({viewHeight:global.innerHeight,viewWidth:global.innerWidth});let e=o(document.body),t=global.innerHeight,i=Number(e.getStyleProperty("--topNavHeight").removeLetters()),l=Number(e.getStyleProperty("--footerNavHeight").removeLetters()),g=t-i-l;e.setStyleProperty("--viewHeight",t+"px").setStyleProperty("--sideNavHeight",g+"px").setStyleProperty("--contentHeight",g+"px")}}),a();
@@ -1 +1 @@
1
- import{e as y}from"../chunk-VY3566IV.js";import i from"@mingoo/jsmin";let J="https://cdn.amotify.com/";i.CDNReader=r=>new Promise((f,e)=>{if(!r)return f(!1);let t=document.createElement("script");t.src=r,t.addEventListener("load",()=>{f(!0)}),i(document.body).append(t)});{const r=(e,t)=>new r.fn.SpreadSheet(e,t);r.fn=r.prototype={},i.extend({SpreadSheet:function(e,t){this.ok=!0;try{this.workbook=e,this.fileName=t}catch(s){console.log(s),this.ok=!1}return this},isValid:function(){return this.ok},getWorkbook:function(){return this.workbook},updateFileName:function(e){return this.fileName=e,this},updateMerges:function(e){this.toJson().sheets.forEach((s,o)=>{let l=e[o];const c=this.workbook.getWorksheet(s.sheetName);for(let[n,a]of l)n&&a&&c.mergeCells(n+":"+a)})},updateStyles:function(e){this.toJson().sheets.forEach((s,o)=>{let l=e[o];const c=this.workbook.getWorksheet(s.sheetName);for(let n of l){let{type:a,target:p,values:h}=n,u=i.flatArray(p);for(let[d,m]of Object.entries(h))for(let w of u)c["get"+a.toCapital()](w)[d]=m}})},toJson:function(){let e={fileName:this.fileName,sheets:[]};return this.workbook.eachSheet((t,s)=>{let o={sheetName:t.name,rows:[]};t.eachRow((l,c)=>{let[n,...a]=l.values;o.rows.push(a)}),e.sheets.push(o)}),e},export:function(e){return y(this,null,function*(){e=e||"xlsx";const t=yield this.workbook[e].writeBuffer(),s=new Blob([t],{type:"application/octet-binary"}),o=document.createElement("a");o.href=(window.URL||window.webkitURL).createObjectURL(s),o.download=this.fileName+"."+e,o.click(),o.remove()})}},r),r.fn.SpreadSheet.prototype=r.fn,r.fn.SpreadSheet.prototype.constructor=r;let f=J+"@env/@foreign/exceljs.min.js";i.spreadSheet={readFromFile:e=>y(void 0,null,function*(){if(window.ExcelJS||(yield i.CDNReader(f)),!window.ExcelJS)return;let t=e.type,s=e.name.replace(/\.[^/.]+$/,"");if(t.match(/csv/)){const n=(yield e.text()).split(/[\n\r]+/).map(h=>h.split(/,/)),a=new ExcelJS.Workbook,p=a.addWorksheet("Sheet1");return n.forEach(h=>p.addRow(h)),r(a,s)}const o=new ExcelJS.Workbook,l=(yield e.read("binaryString")).target.result;return r(yield o.xlsx.load(l),s)}),readFromJson:e=>y(void 0,null,function*(){if(window.ExcelJS||(yield i.CDNReader(f)),!window.ExcelJS)return;let{sheets:t,fileName:s=""}=e;s=s||i.uuid.gen();const o=new ExcelJS.Workbook;return t.forEach((l,c)=>{let{sheetName:n,rows:a,merges:p=[],styles:h=[]}=l;n=n||"\u30B7\u30FC\u30C8"+(c+1),o.addWorksheet(n);const u=o.getWorksheet(n);u.addRows(a);for(let[d,m]of p)d&&m&&u.mergeCells(d+":"+m);for(let d of h){let{type:m,target:w,values:S}=d,g=i.flatArray(w);for(let[k,x]of Object.entries(S))for(let b of g)u["get"+m.toCapital()](b)[k]=x}}),r(o,s)})}}export{i as $$,i as default};
1
+ import{e as y}from"../chunk-VY3566IV.js";import i from"@mingoo/jsmin";let J="https://cdn.amotify.com/";i.CDNReader=r=>new Promise((f,e)=>{if(!r)return f(!1);let t=document.createElement("script");t.src=r,t.addEventListener("load",()=>{f(!0)}),i(document.body).append(t)});{const r=(e,t)=>new r.fn.SpreadSheet(e,t);r.fn=r.prototype={},i.extend({SpreadSheet:function(e,t){this.ok=!0;try{this.workbook=e,this.fileName=t}catch(s){console.log(s),this.ok=!1}return this},isValid:function(){return this.ok},getWorkbook:function(){return this.workbook},updateFileName:function(e){return this.fileName=e,this},updateMerges:function(e){this.toJson().sheets.forEach((s,o)=>{let l=e[o];const c=this.workbook.getWorksheet(s.sheetName);for(let[n,a]of l)n&&a&&c.mergeCells(n+":"+a)})},updateStyles:function(e){this.toJson().sheets.forEach((s,o)=>{let l=e[o];const c=this.workbook.getWorksheet(s.sheetName);for(let n of l){let{type:a,target:p,values:h}=n,u=i.flatArray(p);for(let[d,m]of Object.entries(h))for(let g of u)c["get"+a.toCapital()](g)[d]=m}})},toJson:function(){let e={fileName:this.fileName,sheets:[]};return this.workbook.eachSheet((t,s)=>{let o={sheetName:t.name,rows:[]};t.eachRow((l,c)=>{let[n,...a]=l.values;o.rows.push(a)}),e.sheets.push(o)}),e},export:function(e){return y(this,null,function*(){e=e||"xlsx";const t=yield this.workbook[e].writeBuffer(),s=new Blob([t],{type:"application/octet-binary"}),o=document.createElement("a");o.href=(global.URL||global.webkitURL).createObjectURL(s),o.download=this.fileName+"."+e,o.click(),o.remove()})}},r),r.fn.SpreadSheet.prototype=r.fn,r.fn.SpreadSheet.prototype.constructor=r;let f=J+"@env/@foreign/exceljs.min.js";i.spreadSheet={readFromFile:e=>y(void 0,null,function*(){if(global.ExcelJS||(yield i.CDNReader(f)),!global.ExcelJS)return;let t=e.type,s=e.name.replace(/\.[^/.]+$/,"");if(t.match(/csv/)){const n=(yield e.text()).split(/[\n\r]+/).map(h=>h.split(/,/)),a=new ExcelJS.Workbook,p=a.addWorksheet("Sheet1");return n.forEach(h=>p.addRow(h)),r(a,s)}const o=new ExcelJS.Workbook,l=(yield e.read("binaryString")).target.result;return r(yield o.xlsx.load(l),s)}),readFromJson:e=>y(void 0,null,function*(){if(global.ExcelJS||(yield i.CDNReader(f)),!global.ExcelJS)return;let{sheets:t,fileName:s=""}=e;s=s||i.uuid.gen();const o=new ExcelJS.Workbook;return t.forEach((l,c)=>{let{sheetName:n,rows:a,merges:p=[],styles:h=[]}=l;n=n||"\u30B7\u30FC\u30C8"+(c+1),o.addWorksheet(n);const u=o.getWorksheet(n);u.addRows(a);for(let[d,m]of p)d&&m&&u.mergeCells(d+":"+m);for(let d of h){let{type:m,target:g,values:S}=d,k=i.flatArray(g);for(let[w,b]of Object.entries(S))for(let x of k)u["get"+m.toCapital()](x)[w]=b}}),r(o,s)})}}export{i as $$,i as default};
@@ -1 +1 @@
1
- import"../chunk-VY3566IV.js";import{useStore as s}from"./useStore";const n={open:e=>{window.open(e)},pushSync:e=>{window.location.href=e},pushAsync:e=>{if(e.match(/https?:\/\//)){n.pushSync(e);return}let t=s.get("navigate");t&&t(e)},push:(e,t)=>{if(t){n.open(e);return}n.pushAsync(e)},back:()=>{let e=s.get("navigate");e&&e(-1)}};export{n as default,n as pageTransit};
1
+ import"../chunk-VY3566IV.js";import{useStore as a}from"./useStore";const t={open:e=>{global.open(e)},pushSync:e=>{global.location.href=e},pushAsync:e=>{if(e.match(/https?:\/\//)){t.pushSync(e);return}let n=a.get("navigate");n&&n(e)},push:(e,n)=>{if(n){t.open(e);return}t.pushAsync(e)},back:()=>{let e=a.get("navigate");e&&e(-1)}};export{t as default,t as pageTransit};
@@ -1 +1 @@
1
- import{b as I,c as T,d as B}from"../../chunk-VY3566IV.js";import{jsx as d,jsxs as M}from"react/jsx-runtime";import{useState as A,useEffect as P}from"react";import{$$ as c,$$fromRoot as L,useStore as E,GenerateClassName as q}from"../../@utils";import x from"../../atoms/Box";import F from"../../atoms/Flex";import O from"../../mols/Column";import G from"../Button";import{Wrapper as X,BoxWrapper as j,SubmitForm as J,CommonEffects as Q}from"./core";import Y from"./Hidden";import{InputSliderClasses as v}from"../../@styles/componentClasses";function Z(a){let{value:e,para:o}=a,{required:n}=o,s=[];return n&&!e&&s.push({type:"invalid",label:"\u5FC5\u9808\u9805\u76EE\u3067\u3059"}),{ok:!s.filter(({type:i})=>i=="invalid").length,notice:s}}const N=a=>{let{value:e,val_status:o}=a,{min:n,max:s,step:i}=o;e=Math.max(e,n),e=Math.min(e,s);let t=e/s*s;return t=Math.round(t/i),{stepValue:t*i,stepIndex:t,positionLeft:t*i/s*100+"%"}},z={IndicatorLabels:a=>{let{componentID:e,min:o,max:n,step:s,customLegends:i}=a,r=[],t=Math.round(o/s),p=Math.round(n/s),f=p-t+1;for(var u=t;u<=p;u++){let l=u*s;l=Math.max(l,o),l=Math.min(l,n);let g=l/n*100+"%";r.push(d(x,{className:v("Label"),id:"Legend-"+e+"-"+u,display:u==t||u==p?"flex":"none",position:"absolute",top:0,unitHeight:1,unitWidth:1.5,transition:"middle",fontColor:"1.clear",freeCSS:{left:g,whiteSpace:"nowrap",textAlign:"center"},verticalAlign:"center",horizontalAlign:"center",children:i?i(l):l.rank()},l))}return P(()=>{const l=()=>{let g=L("#Labels-"+e),{width:S}=g.position(),C=Math.round(S/50)-1,y=Math.round(f/C);for(let m=t+1;m<p;m++)L("#Legend-"+e+"-"+m).css({display:m%y==0?"flex":"none"})};return c(window).addEvent({eventID:"SliderResizeCallback-"+e,eventType:"resize",callback:()=>{l()}}),l(),()=>{c(window).removeEvent("SliderResizeCallback-"+e)}},[]),d(F,{className:v("Labels"),verticalAlign:"center",horizontalAlign:"between",fontSize:"0.xs",position:"relative",unitHeight:1,id:"Labels-"+e,children:d(x,{position:"absolute",top:0,left:0,bottom:0,freeCSS:{right:12*1.5},children:r})})},Rail:a=>{let{val_status:e,set_status:o,DotData:n,form:s,enableFormSubmit:i}=a,{componentID:r}=e;return M(F,{className:v("Rail"),position:"relative",paddingLeft:"1/2",unitHeight:1.5,verticalAlign:"center",freeCSS:{minWidth:"10rem",zIndex:1,cursor:"pointer"},onMouseDown:t=>{t.stopPropagation(),b.Effects.Start(t,{val_status:e,set_status:o,DotData:n})},onTouchStart:t=>{t.stopPropagation(),b.Effects.Start(t,{val_status:e,set_status:o,DotData:n})},children:[d(x,{className:v("Bar"),backgroundColor:"layer.4",position:"relative",borderRadius:"sphere",transition:"middle",flexSizing:"none",unitHeight:"2/3",width:1,id:r+"_Bar",children:d(x,{className:v("BarColor"),position:"relative",height:1,width:0,left:0,transition:"long",borderRadius:"inherit",backgroundColor:a.color,opacity:"middle",overflow:"hidden",freeCSS:{width:n.positionLeft},id:r+"_BarColor"})}),d(x,{className:v("BallWrap"),position:"absolute",top:0,left:0,bottom:0,freeCSS:{right:12*1.5},children:d(G.Button.Plain,{className:v("Ball"),position:"absolute",backgroundColor:a.color,top:0,left:0,ssSphere:1.5,freeCSS:{zIndex:2,left:n.positionLeft},"data-form-name":s,id:r+"_Ball",onKeyDown:t=>{b.KeyDownEvent({event:t,val_status:e,set_status:o,DotData:n}),i&&J(t)}})})]})}},b={Effects:{Start:(a,e)=>{c(document).addEvent({eventID:"SliderMouseMove",eventType:"mousemove",callback:o=>{b.Effects.Move(o,e)},options:{passive:!1}}).addEvent({eventID:"SliderTouchMove",eventType:"touchmove",callback:o=>{b.Effects.Move(o,e)},options:{passive:!1}}).addEvent({eventID:"SliderMouseUp",eventType:"mouseup",callback:()=>{b.Effects.End()}}).addEvent({eventID:"SliderTouchEnd",eventType:"touchend",callback:()=>{b.Effects.End()}})},Move:(a,e)=>{let o=c.getCursor(a).x,{val_status:n,set_status:s}=e,{componentID:i,min:r,max:t}=n,p=L("#"+i+"_Ball"),f=L("#"+i+"_Bar"),u=L("#"+i+"_BarColor"),{width:l,left:g}=f.position(),S=(o-g)/l;S=Math.max(S,0),S=Math.min(S,1);let C=S*t,y=N({value:C,val_status:n}),m=y.positionLeft,D=y.stepValue;p.css({left:m}),u.css({width:m});let{prevValue:_}=E.get(i);return D!=_&&(E.update({key:i,value:{prevValue:D}}),s(T(I({},n),{dataValue:D,eventType:"update",eventID:c.uuid.gen()}))),a.preventDefault(),a.stopPropagation(),!1},End:()=>{c(document).removeEvent(["SliderMouseMove","SliderTouchMove","SliderMouseUp","SliderTouchEnd"])}},KeyDownEvent:a=>{let{event:e,val_status:o,set_status:n}=a,{min:s,max:i,step:r}=o,{key:t,metaKey:p,ctrlKey:f}=e,u=f||p,l=o.dataValue;t.match(/Arrow/)&&(e.preventDefault(),t.match(/Left|Up/)?u?l=s:l-=r:t.match(/Right|Down/)&&(u?l=i:l+=r),l=Math.max(Math.min(l,i),s),E.update({key:o.componentID,value:{prevValue:l}}),n(T(I({},o),{dataValue:l,eventType:"update",eventID:c.uuid.gen()})))}},ee=a=>{let k=a,{color:e="theme",required:o,form:n="",legends:{enable:s=!0,custom:i,showAlways:r=!1}={},min:t,max:p,step:f,enableFormSubmit:u,checkValidationAtFirst:l,onChange:g,onKeyDown:S,onValidate:C,onUpdateValue:y,onUpdateValidValue:m,value:D="",className:_}=k,K=B(k,["color","required","form","legends","min","max","step","enableFormSubmit","checkValidationAtFirst","onChange","onKeyDown","onValidate","onUpdateValue","onUpdateValidValue","value","className"]),W={componentID:a.componentID||"",dataValue:D,min:t,max:p,step:f,eventType:"init",eventID:c.uuid.gen()},[h,V]=A(W),[w,U]=A({ok:!1,notice:[]});Q({para:a,val_status:h,set_status:V,val_validate:w,set_validate:U,onUpdateValue:y,onUpdateValidValue:m,DefaultValidation:Z,ExtraOverrideParams:{dataValue:D},ExtraStoreParams:{prevValue:h.dataValue,setValueByForeign:$=>{V(T(I({},h),{dataValue:$,eventType:"update",eventID:c.uuid.gen()}))}}});let R=N({value:h.dataValue,val_status:h});return M(j,{val_status:h,set_status:V,val_validate:w,para:a,children:[d(Y,I({value:R.stepValue,form:n,"data-value":R.stepValue,"data-validation":w.ok,"data-input-type":"slider"},K)),M(O,{gap:"1/2",flexSizing:"auto",className:[v("Wrap"),_,v("ShowLegendsAlways_"+r)].join(" "),children:[d(z.Rail,{color:e,val_status:h,set_status:V,DotData:R,form:n,enableFormSubmit:u}),!!s&&d(z.IndicatorLabels,{componentID:h.componentID,min:t,max:p,step:f,customLegends:i})]})]})},H=a=>(a=I({},a),d(X,{componentID:a.componentID,children:ee,para:q(a)}));export{H as Slider,H as default};
1
+ import{b as I,c as T,d as B}from"../../chunk-VY3566IV.js";import{jsx as d,jsxs as w}from"react/jsx-runtime";import{useState as A,useEffect as P}from"react";import{$$ as c,$$fromRoot as L,useStore as M,GenerateClassName as q}from"../../@utils";import x from"../../atoms/Box";import F from"../../atoms/Flex";import O from"../../mols/Column";import G from"../Button";import{Wrapper as X,BoxWrapper as j,SubmitForm as J,CommonEffects as Q}from"./core";import Y from"./Hidden";import{InputSliderClasses as v}from"../../@styles/componentClasses";function Z(a){let{value:e,para:o}=a,{required:n}=o,s=[];return n&&!e&&s.push({type:"invalid",label:"\u5FC5\u9808\u9805\u76EE\u3067\u3059"}),{ok:!s.filter(({type:i})=>i=="invalid").length,notice:s}}const N=a=>{let{value:e,val_status:o}=a,{min:n,max:s,step:i}=o;e=Math.max(e,n),e=Math.min(e,s);let t=e/s*s;return t=Math.round(t/i),{stepValue:t*i,stepIndex:t,positionLeft:t*i/s*100+"%"}},z={IndicatorLabels:a=>{let{componentID:e,min:o,max:n,step:s,customLegends:i}=a,r=[],t=Math.round(o/s),p=Math.round(n/s),f=p-t+1;for(var u=t;u<=p;u++){let l=u*s;l=Math.max(l,o),l=Math.min(l,n);let g=l/n*100+"%";r.push(d(x,{className:v("Label"),id:"Legend-"+e+"-"+u,display:u==t||u==p?"flex":"none",position:"absolute",top:0,unitHeight:1,unitWidth:1.5,transition:"middle",fontColor:"1.clear",freeCSS:{left:g,whiteSpace:"nowrap",textAlign:"center"},verticalAlign:"center",horizontalAlign:"center",children:i?i(l):l.rank()},l))}return P(()=>{const l=()=>{let g=L("#Labels-"+e),{width:S}=g.position(),C=Math.round(S/50)-1,y=Math.round(f/C);for(let m=t+1;m<p;m++)L("#Legend-"+e+"-"+m).css({display:m%y==0?"flex":"none"})};return c(global).addEvent({eventID:"SliderResizeCallback-"+e,eventType:"resize",callback:()=>{l()}}),l(),()=>{c(global).removeEvent("SliderResizeCallback-"+e)}},[]),d(F,{className:v("Labels"),verticalAlign:"center",horizontalAlign:"between",fontSize:"0.xs",position:"relative",unitHeight:1,id:"Labels-"+e,children:d(x,{position:"absolute",top:0,left:0,bottom:0,freeCSS:{right:12*1.5},children:r})})},Rail:a=>{let{val_status:e,set_status:o,DotData:n,form:s,enableFormSubmit:i}=a,{componentID:r}=e;return w(F,{className:v("Rail"),position:"relative",paddingLeft:"1/2",unitHeight:1.5,verticalAlign:"center",freeCSS:{minWidth:"10rem",zIndex:1,cursor:"pointer"},onMouseDown:t=>{t.stopPropagation(),h.Effects.Start(t,{val_status:e,set_status:o,DotData:n})},onTouchStart:t=>{t.stopPropagation(),h.Effects.Start(t,{val_status:e,set_status:o,DotData:n})},children:[d(x,{className:v("Bar"),backgroundColor:"layer.4",position:"relative",borderRadius:"sphere",transition:"middle",flexSizing:"none",unitHeight:"2/3",width:1,id:r+"_Bar",children:d(x,{className:v("BarColor"),position:"relative",height:1,width:0,left:0,transition:"long",borderRadius:"inherit",backgroundColor:a.color,opacity:"middle",overflow:"hidden",freeCSS:{width:n.positionLeft},id:r+"_BarColor"})}),d(x,{className:v("BallWrap"),position:"absolute",top:0,left:0,bottom:0,freeCSS:{right:12*1.5},children:d(G.Button.Plain,{className:v("Ball"),position:"absolute",backgroundColor:a.color,top:0,left:0,ssSphere:1.5,freeCSS:{zIndex:2,left:n.positionLeft},"data-form-name":s,id:r+"_Ball",onKeyDown:t=>{h.KeyDownEvent({event:t,val_status:e,set_status:o,DotData:n}),i&&J(t)}})})]})}},h={Effects:{Start:(a,e)=>{c(document).addEvent({eventID:"SliderMouseMove",eventType:"mousemove",callback:o=>{h.Effects.Move(o,e)},options:{passive:!1}}).addEvent({eventID:"SliderTouchMove",eventType:"touchmove",callback:o=>{h.Effects.Move(o,e)},options:{passive:!1}}).addEvent({eventID:"SliderMouseUp",eventType:"mouseup",callback:()=>{h.Effects.End()}}).addEvent({eventID:"SliderTouchEnd",eventType:"touchend",callback:()=>{h.Effects.End()}})},Move:(a,e)=>{let o=c.getCursor(a).x,{val_status:n,set_status:s}=e,{componentID:i,min:r,max:t}=n,p=L("#"+i+"_Ball"),f=L("#"+i+"_Bar"),u=L("#"+i+"_BarColor"),{width:l,left:g}=f.position(),S=(o-g)/l;S=Math.max(S,0),S=Math.min(S,1);let C=S*t,y=N({value:C,val_status:n}),m=y.positionLeft,D=y.stepValue;p.css({left:m}),u.css({width:m});let{prevValue:_}=M.get(i);return D!=_&&(M.update({key:i,value:{prevValue:D}}),s(T(I({},n),{dataValue:D,eventType:"update",eventID:c.uuid.gen()}))),a.preventDefault(),a.stopPropagation(),!1},End:()=>{c(document).removeEvent(["SliderMouseMove","SliderTouchMove","SliderMouseUp","SliderTouchEnd"])}},KeyDownEvent:a=>{let{event:e,val_status:o,set_status:n}=a,{min:s,max:i,step:r}=o,{key:t,metaKey:p,ctrlKey:f}=e,u=f||p,l=o.dataValue;t.match(/Arrow/)&&(e.preventDefault(),t.match(/Left|Up/)?u?l=s:l-=r:t.match(/Right|Down/)&&(u?l=i:l+=r),l=Math.max(Math.min(l,i),s),M.update({key:o.componentID,value:{prevValue:l}}),n(T(I({},o),{dataValue:l,eventType:"update",eventID:c.uuid.gen()})))}},ee=a=>{let k=a,{color:e="theme",required:o,form:n="",legends:{enable:s=!0,custom:i,showAlways:r=!1}={},min:t,max:p,step:f,enableFormSubmit:u,checkValidationAtFirst:l,onChange:g,onKeyDown:S,onValidate:C,onUpdateValue:y,onUpdateValidValue:m,value:D="",className:_}=k,K=B(k,["color","required","form","legends","min","max","step","enableFormSubmit","checkValidationAtFirst","onChange","onKeyDown","onValidate","onUpdateValue","onUpdateValidValue","value","className"]),W={componentID:a.componentID||"",dataValue:D,min:t,max:p,step:f,eventType:"init",eventID:c.uuid.gen()},[b,V]=A(W),[R,U]=A({ok:!1,notice:[]});Q({para:a,val_status:b,set_status:V,val_validate:R,set_validate:U,onUpdateValue:y,onUpdateValidValue:m,DefaultValidation:Z,ExtraOverrideParams:{dataValue:D},ExtraStoreParams:{prevValue:b.dataValue,setValueByForeign:$=>{V(T(I({},b),{dataValue:$,eventType:"update",eventID:c.uuid.gen()}))}}});let E=N({value:b.dataValue,val_status:b});return w(j,{val_status:b,set_status:V,val_validate:R,para:a,children:[d(Y,I({value:E.stepValue,form:n,"data-value":E.stepValue,"data-validation":R.ok,"data-input-type":"slider"},K)),w(O,{gap:"1/2",flexSizing:"auto",className:[v("Wrap"),_,v("ShowLegendsAlways_"+r)].join(" "),children:[d(z.Rail,{color:e,val_status:b,set_status:V,DotData:E,form:n,enableFormSubmit:u}),!!s&&d(z.IndicatorLabels,{componentID:b.componentID,min:t,max:p,step:f,customLegends:i})]})]})},H=a=>(a=I({},a),d(X,{componentID:a.componentID,children:ee,para:q(a)}));export{H as Slider,H as default};
@@ -1 +1 @@
1
- import{b as o,c as I,d as F}from"../../chunk-VY3566IV.js";import{Fragment as P,jsx as n,jsxs as W}from"react/jsx-runtime";import{useState as E,useEffect as w}from"react";import{$$ as x,$$fromRoot as ae,useStore as re}from"../../@utils";import C from"../../atoms/Box";import U from"../../atoms/FAI";import K from"../Button";import R from"../Tooltips";import{faEye as Z}from"@fortawesome/free-solid-svg-icons/faEye";import{Wrapper as ne,BoxWrapper as ie,SubmitForm as oe,CommonEffects as le,DefaultStyles as ue}from"./core";import S from"./Parts";const se={number:{reg:/^-?[0-9\.]+$/g,exist:!0,reason:"\u534A\u89D2\u6570\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},katakana:{reg:/^[ァ-ヶー  ヲ-゚  ]*$/g,exist:!0,reason:"\u30AB\u30BF\u30AB\u30CA\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},"hankaku.katakana":{reg:/^[ヲ-゚  ]*$/g,exist:!0,reason:"\u534A\u89D2\u30AB\u30BF\u30AB\u30CA\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},digitNumber:{reg:/^-?[0-9\.]+$/g,exist:!0,reason:"\u534A\u89D2\u6570\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},fileName:{reg:/[¥\/:*\?\"\'\|\.\s\n\r\<\>]/g,exist:!1,reason:"\u7A7A\u767D\u307E\u305F\u306F\u4E00\u90E8\u306E\u7279\u6B8A\u6587\u5B57\u306F\u4F7F\u7528\u3067\u304D\u307E\u305B\u3093"},creditCard:{reg:/^\d{14,16}$/g,exist:!0,reason:"14~16\u6841\u306E\u6570\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},email:{reg:/^[A-Za-z0-9]{1}[A-Za-z0-9_.-]*@{1}[A-Za-z0-9_.-]+\.[A-Za-z0-9]+$/,exist:!0,reason:W(P,{children:[n(C,{children:"\u25CB\u25CB\u25CB\u25CB@\u25CB\u25CB\u25CB\u25CB.\u25CB\u25CB\u25CB\u306E\u5F62\u5F0F\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"}),n(C,{children:"\u6700\u5F8C\u306E\u6587\u5B57\u306B.(\u30C9\u30C3\u30C8)\u3092\u5165\u308C\u308B\u3053\u3068\u306F\u3067\u304D\u307E\u305B\u3093"})]})},password:{reg:/^(?=[^A-Z]*[A-Z])(?=[^a-z]*[a-z])(?=[^0-9]*[0-9]).{8,}$/,exist:!0,reason:"8\u6587\u5B57\u4EE5\u4E0A\u3001\u534A\u89D2\u82F1\u6570\u5927\u5C0F\u6587\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},tel:{reg:/.*$/g,exist:!0,reason:W(P,{children:[n(C,{children:"0\u304B\u3089\u59CB\u307E\u308B\u756A\u53F7\u306E\u307F\u5165\u529B\u53EF\u80FD\u3067\u3059"}),n(C,{children:"9~12\u6841\u306E\u6570\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"}),n(C,{children:"\u6570\u5B57\u306E\u307F\u5165\u529B\u53EF\u80FD\u3067\u3059"})]})},url:{reg:/^https?:\/\/[^\n\s]+(\.|\:)[^\n\s\.\:]+$/,exist:!0,reason:"URL\u5F62\u5F0F : http(s)://\u25EF\u25EF\u25EF\u25EF"},postal:{reg:/^\d{7}$/g,exist:!0,reason:"7\u6841\u306E\u6570\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"}},T=e=>{let{restrict:r,value:s=""}=e,t=String(s),a=!1;if(["tel","number","digitNumber","test","postal","creditCard"].includes(r)&&(t=t.zen2hanNumber()),r=="katakana"&&(t=t.replace(/[^ァ-ヶー  ヲ-゚  ]/ig,"")),r=="hankaku.katakana"&&(t=t.replace(/[^ヲ-゚  ]/ig,"")),["postal","creditCard"].includes(r)&&(t=t.removeLetters()),["number","digitNumber"].includes(r)&&t&&t!="-")if(t=="0-")t="-";else{t[0]=="-"&&(a=!0),t=t.replace(/[^0-9\.]/ig,"");let i=Number(t);i===0&&(a=!1),a&&(i=-1*i),x.is.exist(e.min)&&(i=Math.max(i,Number(e.min))),x.is.exist(e.max)&&(i=Math.min(i,Number(e.max))),t=String(Math.abs(i))}let p=t;if(r=="digitNumber"){if(t&&t!="-"){let i=[];for(let l=t.length-1;l>=0;l--){i.unshift(t[l]);let g=t.length-1-l+1;l!=0&&g%3==0&&i.unshift(",")}p=i.join("")}}else r=="postal"?t.length>=4&&(p=t.clip(0,3)+"-"+t.clip(3)):r=="creditCard"&&(p=t.replace(/.{4}(?=.)/g,"$& "));return["number","digitNumber"].includes(r)&&a&&(t="-"+t,p="-"+p),{formatValue:p,dataValue:t}},pe=e=>{let{id:r,restrict:s,val_status:t}=e,a=ae("#"+r)[0];if(a&&t.prevValue&&t.formatValue){let{formatValue:p,prevValue:i,caretFrom:l,caretTo:g}=t;if(s=="creditCard")p.length>=i.length&&l%5==0&&(l++,g++),a.setSelectionRange(l,g);else if(s=="postal")p.length==5&&i.length==3&&(l++,g++),a.setSelectionRange(l,g);else if(s=="digitNumber"){let D=p.length-i.length;D==2&&(l++,g++),D==-2&&(l--,g--),a.setSelectionRange(l,g)}}},H=(e,r)=>{let s={ok:!0,body:""};return(()=>{let t=se[r];if(!t)return;let a=t.reason;if(t){let p=!!(+!!e.match(t.reg)^+!t.exist);s={ok:p,body:p?"":a}}})(),s};function de(e){let{value:r,para:s}=e,{restrict:t="text",maxLength:a=255,required:p}=s,i=[];if(x.is.exist(a)&&r.length>=Number(a)&&i.push({type:"invalid",label:a+"\u5B57\u4EE5\u5185\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"}),r){let l=H(r,t);l.ok||i.push({type:"invalid",label:l.body})}else p&&i.push({type:"invalid",label:"\u5FC5\u9808\u9805\u76EE\u3067\u3059"});return{ok:!i.filter(({type:l})=>l=="invalid").length,notice:i}}const me=e=>{let O=e,{componentID:r,tone:s,required:t,restrict:a="text",form:p,autoComplete:i="off",autoCapitalize:l="off",enableFormSubmit:g,clearButton:D=!1,checkValidationAtFirst:ce,onChange:M,onKeyDown:$,onValidate:fe,onUpdateValue:q,onUpdateValidValue:Y,value:X="",leftIndicator:ge,rightIndicator:xe,leftIcon:be,rightIcon:he,maxLength:Ie,min:y,max:N}=O,m=F(O,["componentID","tone","required","restrict","form","autoComplete","autoCapitalize","enableFormSubmit","clearButton","checkValidationAtFirst","onChange","onKeyDown","onValidate","onUpdateValue","onUpdateValidValue","value","leftIndicator","rightIndicator","leftIcon","rightIcon","maxLength","min","max"]),j=a=="password"||a=="concealed"?"password":"text",G=["number","digitNumber","creditCard"].includes(a)?"numeric":a=="email"?"email":"text",Q=I(o({componentID:r},T({min:y,max:N,restrict:a,value:X})),{prevValue:"",eventType:"init",eventID:x.uuid.gen(),caretFrom:null,caretTo:null}),[ee,L]=E(!1),[u,v]=E(Q),[k,B]=E({ok:!1,notice:[]});return le({para:e,val_status:u,set_status:v,val_validate:k,set_validate:B,DefaultValidation:de,onUpdateValue:q,onUpdateValidValue:Y,ExtraOverrideParams:o({},T({min:y,max:N,restrict:a,value:X}))}),w(()=>{pe({id:e.id,restrict:a,val_status:u})},[u]),n(ie,{val_status:u,set_status:v,val_validate:k,para:e,children:n("input",I(o({type:j,inputMode:G,"data-form":p,"data-input-type":"text","data-validation":k.ok,"data-value":u.dataValue,"data-component-id":u.componentID,value:u.formatValue,autoComplete:i,autoCapitalize:l,onKeyDown:c=>{let{key:f,target:_}=c;{let b=_,{selectionStart:h,selectionEnd:te}=b,V=Number(h),z=Number(te),A=u.formatValue[Number(V)],J=u.formatValue[Number(V)-1];f=="Delete"&&(a=="creditCard"&&A==" "||a=="postal"&&A=="-"||a=="digitNumber"&&A==",")&&(b.setSelectionRange(V+1,z+1),c.preventDefault()),f=="Backspace"&&(a=="creditCard"&&J==" "||a=="postal"&&J=="-"||a=="digitNumber"&&J==",")&&(b.setSelectionRange(V-1,z-1),c.preventDefault()),f=="Enter"||f=="Tab"}if(["number","digitNumber","creditCard"].includes(a)&&f=="Clear"&&v(I(o({},u),{dataValue:"",formatValue:"",eventType:"update",eventID:x.uuid.gen()})),["number","digitNumber"].includes(a)&&["ArrowUp","ArrowDown"].includes(f)){let b=+(f=="ArrowUp")*2-1,h=String(Number(u.dataValue)+b);k.ok&&B({ok:!1,notice:[]}),v(I(o(o({},u),T({min:y,max:N,restrict:a,value:h})),{eventType:"update",eventID:x.uuid.gen()})),c.preventDefault()}$&&$(c),g&&oe(c)},onChange:c=>{let{value:f,selectionStart:_,selectionEnd:b}=c.target,h=T({min:y,max:N,restrict:a,value:f});ee&&(h.formatValue=f),h.formatValue!=u.formatValue&&(k.ok&&B({ok:!1,notice:[]}),v(I(o(o({},u),h),{prevValue:u.formatValue,eventType:"update",eventID:x.uuid.gen(),caretFrom:Number(_),caretTo:Number(b)})),M&&M(c))}},m),{onCompositionStart:c=>{m!=null&&m.onCompositionStart&&(m==null||m.onCompositionStart(c)),L(!0)},onCompositionEnd:c=>{if(m!=null&&m.onCompositionEnd&&(m==null||m.onCompositionEnd(c)),a=="text")return;let f=T({min:y,max:N,restrict:a,value:u.formatValue});v(I(o(o({},u),f),{prevValue:u.formatValue,eventType:"update",eventID:x.uuid.gen(),caretFrom:Number(u.formatValue.length+1),caretTo:Number(u.formatValue.length+1)})),L(!1)}}))})},d={Validate:H,Normal:e=>{var r,s;return e=o({},e),e.rightIcon&&(e.paddingRight=(r=e.paddingRight)!=null?r:3),e.leftIcon&&(e.paddingLeft=(s=e.paddingLeft)!=null?s:3),n(ne,{componentID:e.componentID,children:me,para:ue.Boxish(e)})},Katakana:e=>n(d.Normal,o({restrict:"katakana"},e)),HankakuKatakana:e=>n(d.Normal,o({restrict:"hankaku.katakana"},e)),CreditCard:e=>n(d.Normal,o({restrict:"creditCard"},e)),Tel:e=>n(d.Normal,o({restrict:"tel",placeholder:"xxx-xxxx-xxxx"},e)),Number:e=>n(d.Normal,o({restrict:"number"},e)),DigitNumber:e=>n(d.Normal,o({restrict:"digitNumber"},e)),Email:e=>n(d.Normal,o({restrict:"email"},e)),Url:e=>n(d.Normal,o({restrict:"url",placeholder:"https://example.com"},e)),Postal:e=>{let[r]=E(x.uuid.gen());return w(()=>()=>{re.delete(r)},[]),n(d.Normal,o({restrict:"postal",placeholder:"\u90F5\u4FBF\u756A\u53F7",leftIndicator:n(S.LeftIndicator,{children:"\u3012"})},e))},Password:e=>n(d.Normal,o({restrict:"password",placeholder:"\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u5165\u529B",rightIndicator:n(S.RightIndicator,{padding:0,children:n(K.Button.Normal.R,{padding:[0,1],fontColor:"theme",borderRadius:"inherit",backgroundColor:"inherit",flexCenter:!0,height:1,ssEffectsOnActive:["expand"],onMouseOver:r=>{R.open({parent:r.currentTarget,gravityPoint:24,padding:[1,0],content:n(R.Comps.Body,{children:"\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u8868\u793A"})})},tabIndex:-1,onClick:r=>{x(r.target).parent().parent().parent().find("input").callback(s=>{let t=s[0];t.type=t.type==="password"?"text":"password"})},children:n(U,{icon:Z})})})},e)),Concealed:e=>n(d.Normal,o({restrict:"concealed",placeholder:"\u79D8\u5BC6\u9375\u3092\u5165\u529B",rightIndicator:n(S.RightIndicator,{padding:0,children:n(K.Button.Normal.R,{padding:[0,1],fontColor:"theme",borderRadius:"inherit",backgroundColor:"inherit",flexCenter:!0,height:1,ssEffectsOnActive:["expand"],onMouseOver:r=>{R.open({parent:r.currentTarget,gravityPoint:24,padding:[1,0],content:n(R.Comps.Body,{children:"\u5024\u3092\u8868\u793A"})})},tabIndex:-1,onClick:r=>{x(r.target).parent().parent().parent().find("input").callback(s=>{let t=s[0];t.type=t.type==="password"?"text":"password"})},children:n(U,{icon:Z})})})},e)),Money:{JPY:e=>n(d.DigitNumber,o({placeholder:"\u91D1\u984D\u3092\u5165\u529B",rightIndicator:n(S.RightIndicator,{children:"\u5186"})},e))}};export{d as Text,me as TextInput,d as default};
1
+ import{b as o,c as I,d as F}from"../../chunk-VY3566IV.js";import{Fragment as P,jsx as n,jsxs as W}from"react/jsx-runtime";import{useState as E,useEffect as w}from"react";import{$$ as x,$$fromRoot as ae,useStore as re}from"../../@utils";import C from"../../atoms/Box";import U from"../../atoms/FAI";import K from"../Button";import R from"../Tooltips";import{faEye as Z}from"@fortawesome/free-solid-svg-icons/faEye";import{Wrapper as ne,BoxWrapper as ie,SubmitForm as oe,CommonEffects as le,DefaultStyles as ue}from"./core";import S from"./Parts";const se={number:{reg:/^-?[0-9\.]+$/g,exist:!0,reason:"\u534A\u89D2\u6570\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},katakana:{reg:/^[ァ-ヶー  ヲ-゚  ]*$/g,exist:!0,reason:"\u30AB\u30BF\u30AB\u30CA\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},"hankaku.katakana":{reg:/^[ヲ-゚  ]*$/g,exist:!0,reason:"\u534A\u89D2\u30AB\u30BF\u30AB\u30CA\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},digitNumber:{reg:/^-?[0-9\.]+$/g,exist:!0,reason:"\u534A\u89D2\u6570\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},fileName:{reg:/[¥\/:*\?\"\'\|\.\s\n\r\<\>]/g,exist:!1,reason:"\u7A7A\u767D\u307E\u305F\u306F\u4E00\u90E8\u306E\u7279\u6B8A\u6587\u5B57\u306F\u4F7F\u7528\u3067\u304D\u307E\u305B\u3093"},creditCard:{reg:/^\d{14,16}$/g,exist:!0,reason:"14~16\u6841\u306E\u6570\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},email:{reg:/^[A-Za-z0-9]{1}[A-Za-z0-9_.-]*@{1}[A-Za-z0-9_.-]+\.[A-Za-z0-9]+$/,exist:!0,reason:W(P,{children:[n(C,{children:"\u25CB\u25CB\u25CB\u25CB@\u25CB\u25CB\u25CB\u25CB.\u25CB\u25CB\u25CB\u306E\u5F62\u5F0F\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"}),n(C,{children:"\u6700\u5F8C\u306E\u6587\u5B57\u306B.(\u30C9\u30C3\u30C8)\u3092\u5165\u308C\u308B\u3053\u3068\u306F\u3067\u304D\u307E\u305B\u3093"})]})},password:{reg:/^(?=[^A-Z]*[A-Z])(?=[^a-z]*[a-z])(?=[^0-9]*[0-9]).{8,}$/,exist:!0,reason:"8\u6587\u5B57\u4EE5\u4E0A\u3001\u534A\u89D2\u82F1\u6570\u5927\u5C0F\u6587\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"},tel:{reg:/.*$/g,exist:!0,reason:W(P,{children:[n(C,{children:"0\u304B\u3089\u59CB\u307E\u308B\u756A\u53F7\u306E\u307F\u5165\u529B\u53EF\u80FD\u3067\u3059"}),n(C,{children:"9~12\u6841\u306E\u6570\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"}),n(C,{children:"\u6570\u5B57\u306E\u307F\u5165\u529B\u53EF\u80FD\u3067\u3059"})]})},url:{reg:/^https?:\/\/[^\n\s]+(\.|\:)[^\n\s\.\:]+$/,exist:!0,reason:"URL\u5F62\u5F0F : http(s)://\u25EF\u25EF\u25EF\u25EF"},postal:{reg:/^\d{7}$/g,exist:!0,reason:"7\u6841\u306E\u6570\u5B57\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"}},T=e=>{let{restrict:r,value:s=""}=e,t=String(s),a=!1;if(["tel","number","digitNumber","test","postal","creditCard"].includes(r)&&(t=t.zen2hanNumber()),r=="katakana"&&(t=t.replace(/[^ァ-ヶー  ヲ-゚  ]/ig,"")),r=="hankaku.katakana"&&(t=t.replace(/[^ヲ-゚  ]/ig,"")),["postal","creditCard"].includes(r)&&(t=t.removeLetters()),["number","digitNumber"].includes(r)&&t&&t!="-")if(t=="0-")t="-";else{t[0]=="-"&&(a=!0),t=t.replace(/[^0-9\.]/ig,"");let i=Number(t);i===0&&(a=!1),a&&(i=-1*i),x.is.exist(e.min)&&(i=Math.max(i,Number(e.min))),x.is.exist(e.max)&&(i=Math.min(i,Number(e.max))),t=String(Math.abs(i))}let p=t;if(r=="digitNumber"){if(t&&t!="-"){let i=[];for(let l=t.length-1;l>=0;l--){i.unshift(t[l]);let g=t.length-1-l+1;l!=0&&g%3==0&&i.unshift(",")}p=i.join("")}}else r=="postal"?t.length>=4&&(p=t.clip(0,3)+"-"+t.clip(3)):r=="creditCard"&&(p=t.replace(/.{4}(?=.)/g,"$& "));return["number","digitNumber"].includes(r)&&a&&(t="-"+t,p="-"+p),{formatValue:p,dataValue:t}},pe=e=>{let{id:r,restrict:s,val_status:t}=e,a=ae("#"+r)[0];if(a&&t.prevValue&&t.formatValue){let{formatValue:p,prevValue:i,caretFrom:l,caretTo:g}=t;if(s=="creditCard")p.length>=i.length&&l%5==0&&(l++,g++),a.setSelectionRange(l,g);else if(s=="postal")p.length==5&&i.length==3&&(l++,g++),a.setSelectionRange(l,g);else if(s=="digitNumber"){let D=p.length-i.length;D==2&&(l++,g++),D==-2&&(l--,g--),a.setSelectionRange(l,g)}}},H=(e,r)=>{let s={ok:!0,body:""};return(()=>{let t=se[r];if(!t)return;let a=t.reason;if(t){let p=!!(+!!e.match(t.reg)^+!t.exist);s={ok:p,body:p?"":a}}})(),s};function de(e){let{value:r,para:s}=e,{restrict:t="text",maxLength:a=255,required:p}=s,i=[];if(x.is.exist(a)&&r.length>=Number(a)&&i.push({type:"invalid",label:a+"\u5B57\u4EE5\u5185\u3067\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"}),r){let l=H(r,t);l.ok||i.push({type:"invalid",label:l.body})}else p&&i.push({type:"invalid",label:"\u5FC5\u9808\u9805\u76EE\u3067\u3059"});return{ok:!i.filter(({type:l})=>l=="invalid").length,notice:i}}const me=e=>{let O=e,{componentID:r,tone:s,required:t,restrict:a="text",form:p,autoComplete:i="off",autoCapitalize:l="off",enableFormSubmit:g,clearButton:D=!1,checkValidationAtFirst:ce,onChange:M,onKeyDown:$,onValidate:fe,onUpdateValue:q,onUpdateValidValue:Y,value:X="",leftIndicator:ge,rightIndicator:xe,leftIcon:be,rightIcon:he,maxLength:Ie,min:y,max:N}=O,m=F(O,["componentID","tone","required","restrict","form","autoComplete","autoCapitalize","enableFormSubmit","clearButton","checkValidationAtFirst","onChange","onKeyDown","onValidate","onUpdateValue","onUpdateValidValue","value","leftIndicator","rightIndicator","leftIcon","rightIcon","maxLength","min","max"]),j=a=="password"||a=="concealed"?"password":"text",G=["number","digitNumber","creditCard"].includes(a)?"numeric":a=="email"?"email":"text",Q=I(o({componentID:r},T({min:y,max:N,restrict:a,value:X})),{prevValue:"",eventType:"init",eventID:x.uuid.gen(),caretFrom:null,caretTo:null}),[ee,L]=E(!1),[u,v]=E(Q),[k,B]=E({ok:!1,notice:[]});return le({para:e,val_status:u,set_status:v,val_validate:k,set_validate:B,DefaultValidation:de,onUpdateValue:q,onUpdateValidValue:Y,ExtraOverrideParams:o({},T({min:y,max:N,restrict:a,value:X}))}),w(()=>{pe({id:e.id,restrict:a,val_status:u})},[u]),n(ie,{val_status:u,set_status:v,val_validate:k,para:e,children:n("input",I(o({type:j,inputMode:G,"data-form":p,"data-input-type":"text","data-validation":k.ok,"data-value":u.dataValue,"data-component-id":u.componentID,value:u.formatValue,autoComplete:i,autoCapitalize:l,onKeyDown:c=>{let{key:f,target:_}=c;{let b=_,{selectionStart:h,selectionEnd:te}=b,V=Number(h),z=Number(te),A=u.formatValue[Number(V)],J=u.formatValue[Number(V)-1];f=="Delete"&&(a=="creditCard"&&A==" "||a=="postal"&&A=="-"||a=="digitNumber"&&A==",")&&(b.setSelectionRange(V+1,z+1),c.preventDefault()),f=="Backspace"&&(a=="creditCard"&&J==" "||a=="postal"&&J=="-"||a=="digitNumber"&&J==",")&&(b.setSelectionRange(V-1,z-1),c.preventDefault()),f=="Enter"||f=="Tab"}if(["number","digitNumber","creditCard"].includes(a)&&f=="Clear"&&v(I(o({},u),{dataValue:"",formatValue:"",eventType:"update",eventID:x.uuid.gen()})),["number","digitNumber"].includes(a)&&["ArrowUp","ArrowDown"].includes(f)){let b=+(f=="ArrowUp")*2-1,h=String(Number(u.dataValue)+b);k.ok&&B({ok:!1,notice:[]}),v(I(o(o({},u),T({min:y,max:N,restrict:a,value:h})),{eventType:"update",eventID:x.uuid.gen()})),c.preventDefault()}$&&$(c),g&&oe(c)},onChange:c=>{let{value:f,selectionStart:_,selectionEnd:b}=c.target,h=T({min:y,max:N,restrict:a,value:f});ee&&(h.formatValue=f),h.formatValue!=u.formatValue&&(k.ok&&B({ok:!1,notice:[]}),v(I(o(o({},u),h),{prevValue:u.formatValue,eventType:"update",eventID:x.uuid.gen(),caretFrom:Number(_),caretTo:Number(b)})),M&&M(c))}},m),{onCompositionStart:c=>{m!=null&&m.onCompositionStart&&(m==null||m.onCompositionStart(c)),L(!0)},onCompositionEnd:c=>{if(m!=null&&m.onCompositionEnd&&(m==null||m.onCompositionEnd(c)),a=="text")return;let f=T({min:y,max:N,restrict:a,value:u.formatValue});v(I(o(o({},u),f),{prevValue:u.formatValue,eventType:"update",eventID:x.uuid.gen(),caretFrom:Number(u.formatValue.length+1),caretTo:Number(u.formatValue.length+1)})),L(!1)}}))})},d={Validate:H,Normal:e=>{var r,s;return e=o({},e),e.rightIcon&&(e.paddingRight=(r=e.paddingRight)!=null?r:3),e.leftIcon&&(e.paddingLeft=(s=e.paddingLeft)!=null?s:3),n(ne,{componentID:e.componentID,children:me,para:ue.Boxish(e)})},Katakana:e=>n(d.Normal,o({restrict:"katakana"},e)),HankakuKatakana:e=>n(d.Normal,o({restrict:"hankaku.katakana"},e)),CreditCard:e=>n(d.Normal,o({restrict:"creditCard"},e)),Tel:e=>n(d.Normal,o({restrict:"tel",placeholder:"xxx-xxxx-xxxx"},e)),Number:e=>n(d.Normal,o({restrict:"number"},e)),DigitNumber:e=>n(d.Normal,o({restrict:"digitNumber"},e)),Email:e=>n(d.Normal,o({restrict:"email"},e)),Url:e=>n(d.Normal,o({restrict:"url",placeholder:"https://example.com"},e)),Postal:e=>{let[r]=E(x.uuid.gen());return w(()=>()=>{re.delete(r)},[]),n(d.Normal,o({restrict:"postal",placeholder:"\u90F5\u4FBF\u756A\u53F7",leftIndicator:n(S.LeftIndicator,{children:"\u3012"})},e))},Password:e=>n(d.Normal,o({restrict:"password",placeholder:"\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u5165\u529B",rightIndicator:n(S.RightIndicator,{padding:0,children:n(K.Button.Normal.R,{padding:[0,1],fontColor:"theme",borderRadius:"inherit",backgroundColor:"inherit",flexCenter:!0,height:1,ssEffectsOnActive:["expand"],onMouseOver:r=>{R.open({parent:r.currentTarget,gravityPoint:24,padding:[1,0],content:n(R.Comps.Body,{children:"\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u8868\u793A"})})},tabIndex:-1,onClick:r=>{x(r.target).parent().parent().find("input").callback(s=>{let t=s[0];t.type=t.type==="password"?"text":"password"})},children:n(U,{icon:Z})})})},e)),Concealed:e=>n(d.Normal,o({restrict:"concealed",placeholder:"\u79D8\u5BC6\u9375\u3092\u5165\u529B",rightIndicator:n(S.RightIndicator,{padding:0,children:n(K.Button.Normal.R,{padding:[0,1],fontColor:"theme",borderRadius:"inherit",backgroundColor:"inherit",flexCenter:!0,height:1,ssEffectsOnActive:["expand"],onMouseOver:r=>{R.open({parent:r.currentTarget,gravityPoint:24,padding:[1,0],content:n(R.Comps.Body,{children:"\u5024\u3092\u8868\u793A"})})},tabIndex:-1,onClick:r=>{x(r.target).parent().parent().parent().find("input").callback(s=>{let t=s[0];t.type=t.type==="password"?"text":"password"})},children:n(U,{icon:Z})})})},e)),Money:{JPY:e=>n(d.DigitNumber,o({placeholder:"\u91D1\u984D\u3092\u5165\u529B",rightIndicator:n(S.RightIndicator,{children:"\u5186"})},e))}};export{d as Text,me as TextInput,d as default};
@@ -1 +1 @@
1
- import"../../chunk-VY3566IV.js";import{jsx as n,jsxs as P}from"react/jsx-runtime";import{useEffect as c,useRef as m}from"react";import{useStore as R}from"../../@utils";import*as s from"react-router-dom";import C from"../Sheet";import{PageNotFound as g}from"./PageNotFound";import{RootViewController as k}from"./RootViewController";const h=(t,o,a)=>{const r=m(!1);let e=s.useLocation(),u=s.useNavigate();R.set({key:"navigate",value:u}),c(()=>{r.current?(C.closeAll(!0),k.fn.updateCSSProperty.reset()):r.current=!0},[e.pathname]),t&&t(e),c(()=>{a&&a(e)},[]),c(()=>{setTimeout(()=>{window.dispatchEvent(new Event("resize"))},200),o&&o(e)},[e])},B=t=>{let{routes:o,beforeCallBack:a,afterCallBack:r,afterFirstCallBack:e}=t;h(a,r,e);let u=o.map(i=>{let{path:l,content:f}=i;return l="/"+l.replace(/^\//,""),n(s.Route,{path:l,element:f},l)});return P(s.Routes,{children:[u,n(s.Route,{path:"*",element:n(g,{})})]})},p=t=>{let{pages:o,beforeCallBack:a,afterCallBack:r,afterFirstCallBack:e}=t;return n(B,{routes:o,beforeCallBack:a,afterCallBack:r,afterFirstCallBack:e})};export{p as PageRouter,p as default};
1
+ import"../../chunk-VY3566IV.js";import{jsx as u,jsxs as P}from"react/jsx-runtime";import{useEffect as c,useRef as m}from"react";import{useStore as R}from"../../@utils";import*as s from"react-router-dom";import C from"../Sheet";import{PageNotFound as g}from"./PageNotFound";import{RootViewController as k}from"./RootViewController";const h=(t,a,o)=>{const r=m(!1);let e=s.useLocation(),n=s.useNavigate();R.set({key:"navigate",value:n}),c(()=>{r.current?(C.closeAll(!0),k.fn.updateCSSProperty.reset()):r.current=!0},[e.pathname]),t&&t(e),c(()=>{o&&o(e)},[]),c(()=>{setTimeout(()=>{global.dispatchEvent(new Event("resize"))},200),a&&a(e)},[e])},B=t=>{let{routes:a,beforeCallBack:o,afterCallBack:r,afterFirstCallBack:e}=t;h(o,r,e);let n=a.map(i=>{let{path:l,content:f}=i;return l="/"+l.replace(/^\//,""),u(s.Route,{path:l,element:f},l)});return P(s.Routes,{children:[n,u(s.Route,{path:"*",element:u(g,{})})]})},p=t=>{let{pages:a,beforeCallBack:o,afterCallBack:r,afterFirstCallBack:e}=t;return u(B,{routes:a,beforeCallBack:o,afterCallBack:r,afterFirstCallBack:e})};export{p as PageRouter,p as default};
@@ -1 +1 @@
1
- import{b as s,c as m,d as y}from"../../chunk-VY3566IV.js";import{jsx as p,jsxs as x}from"react/jsx-runtime";import{useState as S,useEffect as N}from"react";import{$$ as a,$$fromRoot as v,Config as R,pageTransit as P}from"../../@utils";import h from"../../atoms/Box";import C from"../../atoms/Flex";import F from"../../mols/Column";import _ from"../Button";import{LayoutClasses as f}from"../../@styles/componentClasses";const c={Base:o=>{let l=o,{topNavigation:e,sideNavigation:t,footerNavigation:i,children:r,className:n}=l,g=y(l,["topNavigation","sideNavigation","footerNavigation","children","className"]);N(()=>{c.fn.updateCSSProperty.reset(),setTimeout(()=>{c.fn.updateCSSProperty.reset()},100);let u="ResizeCB",B="RemovePageEventCB";return a(window).addEvent({eventType:"resize",eventID:u,callback:()=>{R.get().screen.isPhonepoint()||(a.interval.clear("__RVC_calcHeights"),a.interval.standBy("__RVC_calcHeights",300,()=>{c.fn.updateCSSProperty.reset()}))}}),()=>{a(window).removeEvent(B),a(window).removeEvent(u)}},[]);let d=r;return x(F,m(s({className:[n,f("RootViewController")].join(" "),backgroundColor:"layer.1",gap:0,minHeight:"viewHeight"},g),{children:[e,x(C,{className:f("Body"),flexWrap:!1,position:"relative",flexSizing:0,children:[t,p(h,{className:f("Content"),position:"relative",flexSizing:0,width:0,UnderBreakPointStyles:{width:"auto"},children:d})]}),i]}))},TopNavigation:o=>{let n=o,{className:e,children:t}=n,i=y(n,["className","children"]),[r]=S(a.uuid.gen());return N(()=>{c.fn.updateCSSProperty.topNav()},[]),p(C,m(s({"data-id":r,flexSizing:"none",flexType:"col",position:"sticky",top:0,backgroundColor:"layer.1"},i),{id:"__RVC_TopNavigation",className:[e,f("TopNav")].join(" "),children:t}),r)},SideNavigation:o=>{let r=o,{className:e="",baseStyles:t}=r,i=y(r,["className","baseStyles"]);return p(h,s({flexSizing:"none",className:[e,f("SideNav")].join(" "),minHeight:"sideNavigationHeight"},i))},FooterNavigation:o=>{let n=o,{className:e="",baseStyles:t}=n,i=y(n,["className","baseStyles"]),[r]=S(a.uuid.gen());return N(()=>{c.fn.updateCSSProperty.footer()},[]),p(C,m(s({"data-id":r,borderTop:!0,position:"sticky",bottom:0,overflow:"auto",backgroundColor:"layer.1",paddingBottom:"safeAreaBottom"},t),{id:"__RVC_FooterNavigation",className:[f("FooterNav"),e].join(" "),children:p(C,s({gap:1,flexWrap:!1,padding:"2/3",margin:"auto"},i))}))},Comps:{Button:o=>{let d=o,{isActive:e,uri:t,uriGroup:i}=d,r=y(d,["isActive","uri","uriGroup"]),n=a.flatArray(i),g=location.pathname;{let l=!1;if(a.is.exist(t)&&a.is.string(t)){let u=[location.origin,t.replace(/\//,"")].join("/");l=g==new URL(u).pathname}if(!l&&n.length)for(let u of n)a.is.nullish(u)||g.match(new RegExp(u))&&(l=!0);e=e!=null?e:l}return p(_.Button.Clear.R,s({padding:["3/4",1],display:"flex",gap:"1/2",fontColor:"inherit",width:1,flexSizing:"none",flexWrap:!1,ssEffectsOnActive:"ripple.cloud",verticalAlign:"center",textAlign:"left",isSemiBoldFont:!0,isActive:e,isActiveStyles:{fontColor:"theme",backgroundColor:"cloud"},onClick:l=>{a.is.exist(t)&&a.is.string(t)&&P.push(t,l.ctrlKey||l.metaKey)},color:"cloud"},r))},Bar:o=>p(h,s({flexSizing:"none",backgroundColor:"layer.4.opa.middle",unitHeight:"1/3",margin:["2/3",1],borderRadius:"sphere"},o)),Title:o=>p(h,s({fontSize:"3.paragraph",isSemiBoldFont:!0,padding:[0,1]},o))},fn:{updateCSSProperty:{topNav:()=>{let o=a(document.body),e=v("#__RVC_TopNavigation"),t=e.position().height||0,i=t;e.getStyleProperty("position")!="sticky"&&(i=0),o.setStyleProperty("--topNavHeight",t+"px").setStyleProperty("--topBase",i+"px")},footer:()=>{let o=a(document.body),t=v("#__RVC_FooterNavigation").position().height||0;o.setStyleProperty("--footerNavHeight",t+"px")},reset:()=>{let o=a(document.body),e=v("#__RVC_TopNavigation"),t=v("#__RVC_FooterNavigation"),i=e.position().height||0,r=i,n=t.position().height||0;e.getStyleProperty("position")!="sticky"&&(r=0);let g=window.innerHeight,d=g-i-n;o.setStyleProperty("--topNavHeight",i+"px").setStyleProperty("--topBase",r+"px").setStyleProperty("--footerNavHeight",n+"px").setStyleProperty("--viewHeight",g+"px").setStyleProperty("--sideNavHeight",d+"px").setStyleProperty("--contentHeight",d+"px")}}}};export{c as RootViewController,c as default};
1
+ import{b as s,c as m,d as y}from"../../chunk-VY3566IV.js";import{jsx as p,jsxs as x}from"react/jsx-runtime";import{useState as S,useEffect as N}from"react";import{$$ as a,$$fromRoot as v,Config as R,pageTransit as P}from"../../@utils";import h from"../../atoms/Box";import C from"../../atoms/Flex";import F from"../../mols/Column";import _ from"../Button";import{LayoutClasses as f}from"../../@styles/componentClasses";const c={Base:o=>{let l=o,{topNavigation:e,sideNavigation:t,footerNavigation:i,children:r,className:n}=l,g=y(l,["topNavigation","sideNavigation","footerNavigation","children","className"]);N(()=>{c.fn.updateCSSProperty.reset(),setTimeout(()=>{c.fn.updateCSSProperty.reset()},100);let u="ResizeCB",B="RemovePageEventCB";return a(global).addEvent({eventType:"resize",eventID:u,callback:()=>{R.get().screen.isPhonepoint()||(a.interval.clear("__RVC_calcHeights"),a.interval.standBy("__RVC_calcHeights",300,()=>{c.fn.updateCSSProperty.reset()}))}}),()=>{a(global).removeEvent(B),a(global).removeEvent(u)}},[]);let d=r;return x(F,m(s({className:[n,f("RootViewController")].join(" "),backgroundColor:"layer.1",gap:0,minHeight:"viewHeight"},g),{children:[e,x(C,{className:f("Body"),flexWrap:!1,position:"relative",flexSizing:0,children:[t,p(h,{className:f("Content"),position:"relative",flexSizing:0,width:0,UnderBreakPointStyles:{width:"auto"},children:d})]}),i]}))},TopNavigation:o=>{let n=o,{className:e,children:t}=n,i=y(n,["className","children"]),[r]=S(a.uuid.gen());return N(()=>{c.fn.updateCSSProperty.topNav()},[]),p(C,m(s({"data-id":r,flexSizing:"none",flexType:"col",position:"sticky",top:0,backgroundColor:"layer.1"},i),{id:"__RVC_TopNavigation",className:[e,f("TopNav")].join(" "),children:t}),r)},SideNavigation:o=>{let r=o,{className:e="",baseStyles:t}=r,i=y(r,["className","baseStyles"]);return p(h,s({flexSizing:"none",className:[e,f("SideNav")].join(" "),minHeight:"sideNavigationHeight"},i))},FooterNavigation:o=>{let n=o,{className:e="",baseStyles:t}=n,i=y(n,["className","baseStyles"]),[r]=S(a.uuid.gen());return N(()=>{c.fn.updateCSSProperty.footer()},[]),p(C,m(s({"data-id":r,borderTop:!0,position:"sticky",bottom:0,overflow:"auto",backgroundColor:"layer.1",paddingBottom:"safeAreaBottom"},t),{id:"__RVC_FooterNavigation",className:[f("FooterNav"),e].join(" "),children:p(C,s({gap:1,flexWrap:!1,padding:"2/3",margin:"auto"},i))}))},Comps:{Button:o=>{let d=o,{isActive:e,uri:t,uriGroup:i}=d,r=y(d,["isActive","uri","uriGroup"]),n=a.flatArray(i),g=location.pathname;{let l=!1;if(a.is.exist(t)&&a.is.string(t)){let u=[location.origin,t.replace(/\//,"")].join("/");l=g==new URL(u).pathname}if(!l&&n.length)for(let u of n)a.is.nullish(u)||g.match(new RegExp(u))&&(l=!0);e=e!=null?e:l}return p(_.Button.Clear.R,s({padding:["3/4",1],display:"flex",gap:"1/2",fontColor:"inherit",width:1,flexSizing:"none",flexWrap:!1,ssEffectsOnActive:"ripple.cloud",verticalAlign:"center",textAlign:"left",isSemiBoldFont:!0,isActive:e,isActiveStyles:{fontColor:"theme",backgroundColor:"cloud"},onClick:l=>{a.is.exist(t)&&a.is.string(t)&&P.push(t,l.ctrlKey||l.metaKey)},color:"cloud"},r))},Bar:o=>p(h,s({flexSizing:"none",backgroundColor:"layer.4.opa.middle",unitHeight:"1/3",margin:["2/3",1],borderRadius:"sphere"},o)),Title:o=>p(h,s({fontSize:"3.paragraph",isSemiBoldFont:!0,padding:[0,1]},o))},fn:{updateCSSProperty:{topNav:()=>{let o=a(document.body),e=v("#__RVC_TopNavigation"),t=e.position().height||0,i=t;e.getStyleProperty("position")!="sticky"&&(i=0),o.setStyleProperty("--topNavHeight",t+"px").setStyleProperty("--topBase",i+"px")},footer:()=>{let o=a(document.body),t=v("#__RVC_FooterNavigation").position().height||0;o.setStyleProperty("--footerNavHeight",t+"px")},reset:()=>{let o=a(document.body),e=v("#__RVC_TopNavigation"),t=v("#__RVC_FooterNavigation"),i=e.position().height||0,r=i,n=t.position().height||0;e.getStyleProperty("position")!="sticky"&&(r=0);let g=global.innerHeight,d=g-i-n;o.setStyleProperty("--topNavHeight",i+"px").setStyleProperty("--topBase",r+"px").setStyleProperty("--footerNavHeight",n+"px").setStyleProperty("--viewHeight",g+"px").setStyleProperty("--sideNavHeight",d+"px").setStyleProperty("--contentHeight",d+"px")}}}};export{c as RootViewController,c as default};
@@ -1 +1 @@
1
- import{b as f,c as T,d as k}from"../../chunk-VY3566IV.js";import{jsx as I}from"react/jsx-runtime";import{useState as L,useEffect as M,useRef as N}from"react";import{$$ as c,$$fromRoot as h,useStore as X}from"../../@utils";import R from"../../atoms/Box";import j from"../../atoms/Flex";import{LayoutClasses as a}from"../../@styles/componentClasses";const B=t=>{let D=t,{options:{onSlideCallback:e,visibilitySurroundSlide:u=!0,autoSwipems:d=0,loop:i=!1,disableMousedrag:r=!1,disableTouch:o=!1}={},wrapper:s=n=>n,slides:v=[]}=D,E=k(D,["options","wrapper","slides"]),[w]=L(c.uuid.gen()),[p,y]=L({eventType:"init",index:t.slideIndex});M(()=>{X.set({key:"SwipeTimer-"+w,value:null})},[]);const g=N(!1);M(()=>{y({eventType:"usr",index:t.slideIndex}),g.current||(g.current=!0)},[t.slideIndex]),M(()=>{let n=p.index+(i?1:0),m=[-1,v.length].includes(p.index);m||e&&setTimeout(()=>{e(p.index)},300);let b=h("#Swiper-"+w);if(p.eventType=="adjustLoop")b.await(250).css({transition:"0s",transform:l.TrasformString(n)}).children().removeClass(a("Display")).parent().children(n).addClass([a("Display"),a("LoopAdjusting")]).await(100).removeClass(a("LoopAdjusting"));else if(p.eventType=="sys")b.await(250).css({transform:l.TrasformString(n)}).children().removeClass(a("Display")).parent().children(n).addClass(a("Display"));else if(b.children().removeClass(a("Display")).parent().children(n).addClass(a("Display")).parent().css({transition:"0.3s",transform:l.TrasformString(n)}).await(250).css({transition:"0s"}),m){let x=p.index==-1?v.length-1:0;y({eventType:"adjustLoop",index:x})}d&&!m&&(c.interval.clear("SwipeTimer-"+w),c.interval.standBy("SwipeTimer-"+w,d-(p.eventType=="sys"?310:0),()=>{let x=p.index+1;!i&&x>v.length-1&&(x=0),y({eventType:"usr",index:x})}))},[p]);let S=v.map((n,m)=>I(R,{flexSizing:"none",width:1,height:0,className:a("Child"),children:s(n)},m));i&&(S.push(S[0]),S.unshift(S[S.length-2]));let C={x:0,y:0,process:!1,effectStartAt:0,id:w,loop:i,index:p.index,minIndex:i?-1:0,maxIndex:v.length+(i?1:-1),width:0,set_event:y},A=p.index+(i?1:0);return I(R,T(f({overflow:"hidden",position:"relative"},E),{className:[E.className,a("SwipeView")].join(" "),freeCSS:f({zIndex:1},E.freeCSS),"data-swipe-id":w,onMouseDown:n=>{r||n.buttons==1&&l.EffectStart(n,C)},onTouchStart:n=>{var m;o||((m=n.touches)==null?void 0:m.length)==1&&l.EffectStart(n,C)},children:I(j,{flexWrap:!1,gap:1,transition:"long",className:[a("Rail"),a("ShowOther_"+u)].join(" "),id:"Swiper-"+w,freeCSS:f({},g.current?{}:{transform:l.TrasformString(A)}),children:S})}))},l={TrasformString:t=>`translateX( calc( ${-100*t}% - ${12*t}px ) )`,EffectStart:(t,e)=>{let{x:u,y:d}=c.getCursor(t),i=t.currentTarget,r=t.target;if(["SELECT","BUTTON","LABEL","INPUT"].includes(r.tagName))return;e=T(f({},e),{x:u-e.x+window.scrollX,y:d-e.y+window.scrollY,effectStartAt:new Date().getTime(),width:h("#Swiper-"+e.id).position().width});let{swipeId:o}=i.dataset;o==e.id&&c(document).addEvent({eventID:"SwipeMouseMove",eventType:"mousemove",callback:s=>{l.EffectCheck(s,e)},options:{passive:!1}}).addEvent({eventID:"SwipeTouchMove",eventType:"touchmove",callback:s=>{l.EffectCheck(s,e)},options:{passive:!1}}).addEvent({eventID:"SwipeMouseUp",eventType:"mouseup",callback:s=>{l.EffectEnd(s,e)},options:{passive:!1}}).addEvent({eventID:"SwipeTouchEnd",eventType:"touchend",callback:s=>{l.EffectEnd(s,e)},options:{passive:!1}})},EffectCheck:(t,e)=>{if(e.process)return;let{x:u,y:d}=c.getCursor(t),i=Math.abs(u-e.x+window.scrollX),r=Math.abs(d-e.y+window.scrollY);if(!(t.touches&&t.touches.length>1)&&!(r+i<15))if(r>i/2)c(document).removeEvent(["SwipeMouseMove","SwipeTouchMove"]);else{e.process=!0;let o=e.index+(e.loop?1:0);h("#Swiper-"+e.id).children(o-1).addClass(a("Display")),c(document).addEvent({eventID:"SwipeCheckMouseMove",eventType:"mousemove",callback:s=>{l.EffectMove(s,e)},options:{passive:!1}}).addEvent({eventID:"SwipeCheckTouchMove",eventType:"touchmove",callback:s=>{l.EffectMove(s,e)},options:{passive:!1}}),t.preventDefault();return}},EffectMove:(t,e)=>{if(t.touches&&t.touches.length>1)return;let{x:u}=c.getCursor(t),d=u-e.x+window.scrollX,r=e.index+(e.loop?1:0)-d/e.width;if(r<0)r/=2;else if(r>e.maxIndex){let o=r-e.maxIndex;r=e.maxIndex+o/2}h("#Swiper-"+e.id).css({transition:"0s",transform:l.TrasformString(r)}),t.preventDefault()},EffectEnd:(t,e)=>{if(e.process){let d=c.getCursor(t).x-e.x+window.scrollX,i=new Date().getTime(),r=i-e.effectStartAt,o=e.index+(e.loop?1:0),s=0;r<400?s=o-(+(d>0)*2-1):s=Math.round(o-d/e.width),s=Math.max(Math.min(s,e.maxIndex),e.minIndex),e.process=!1,o===s?(e.effectStartAt=i,h("#Swiper-"+e.id).css({transition:".2s",transform:l.TrasformString(s)}).await(310).css({transition:"0s"}).children().removeClass(a("Display")).parent().children(o).addClass(a("Display"))):e.set_event({eventType:"usr",index:s+e.minIndex})}c(document).removeEvent(["SwipeMouseMove","SwipeTouchMove","SwipeCheckMouseMove","SwipeCheckTouchMove","SwipeMouseUp","SwipeTouchEnd"])}},V=t=>I(B,T(f({},t),{slideIndex:Math.max(Math.min(t.slideIndex,t.slides.length-1),0)}));export{V as SwipeView,V as default};
1
+ import{b as v,c as T,d as k}from"../../chunk-VY3566IV.js";import{jsx as g}from"react/jsx-runtime";import{useState as L,useEffect as M,useRef as N}from"react";import{$$ as c,$$fromRoot as h,useStore as X}from"../../@utils";import R from"../../atoms/Box";import j from"../../atoms/Flex";import{LayoutClasses as a}from"../../@styles/componentClasses";const B=t=>{let D=t,{options:{onSlideCallback:e,visibilitySurroundSlide:u=!0,autoSwipems:d=0,loop:i=!1,disableMousedrag:r=!1,disableTouch:o=!1}={},wrapper:s=n=>n,slides:x=[]}=D,I=k(D,["options","wrapper","slides"]),[S]=L(c.uuid.gen()),[p,y]=L({eventType:"init",index:t.slideIndex});M(()=>{X.set({key:"SwipeTimer-"+S,value:null})},[]);const b=N(!1);M(()=>{y({eventType:"usr",index:t.slideIndex}),b.current||(b.current=!0)},[t.slideIndex]),M(()=>{let n=p.index+(i?1:0),m=[-1,x.length].includes(p.index);m||e&&setTimeout(()=>{e(p.index)},300);let E=h("#Swiper-"+S);if(p.eventType=="adjustLoop")E.await(250).css({transition:"0s",transform:l.TrasformString(n)}).children().removeClass(a("Display")).parent().children(n).addClass([a("Display"),a("LoopAdjusting")]).await(100).removeClass(a("LoopAdjusting"));else if(p.eventType=="sys")E.await(250).css({transform:l.TrasformString(n)}).children().removeClass(a("Display")).parent().children(n).addClass(a("Display"));else if(E.children().removeClass(a("Display")).parent().children(n).addClass(a("Display")).parent().css({transition:"0.3s",transform:l.TrasformString(n)}).await(250).css({transition:"0s"}),m){let w=p.index==-1?x.length-1:0;y({eventType:"adjustLoop",index:w})}d&&!m&&(c.interval.clear("SwipeTimer-"+S),c.interval.standBy("SwipeTimer-"+S,d-(p.eventType=="sys"?310:0),()=>{let w=p.index+1;!i&&w>x.length-1&&(w=0),y({eventType:"usr",index:w})}))},[p]);let f=x.map((n,m)=>g(R,{flexSizing:"none",width:1,height:0,className:a("Child"),children:s(n)},m));i&&(f.push(f[0]),f.unshift(f[f.length-2]));let C={x:0,y:0,process:!1,effectStartAt:0,id:S,loop:i,index:p.index,minIndex:i?-1:0,maxIndex:x.length+(i?1:-1),width:0,set_event:y},A=p.index+(i?1:0);return g(R,T(v({overflow:"hidden",position:"relative"},I),{className:[I.className,a("SwipeView")].join(" "),freeCSS:v({zIndex:1},I.freeCSS),"data-swipe-id":S,onMouseDown:n=>{r||n.buttons==1&&l.EffectStart(n,C)},onTouchStart:n=>{var m;o||((m=n.touches)==null?void 0:m.length)==1&&l.EffectStart(n,C)},children:g(j,{flexWrap:!1,gap:1,transition:"long",className:[a("Rail"),a("ShowOther_"+u)].join(" "),id:"Swiper-"+S,freeCSS:v({},b.current?{}:{transform:l.TrasformString(A)}),children:f})}))},l={TrasformString:t=>`translateX( calc( ${-100*t}% - ${12*t}px ) )`,EffectStart:(t,e)=>{let{x:u,y:d}=c.getCursor(t),i=t.currentTarget,r=t.target;if(["SELECT","BUTTON","LABEL","INPUT"].includes(r.tagName))return;e=T(v({},e),{x:u-e.x+global.scrollX,y:d-e.y+global.scrollY,effectStartAt:new Date().getTime(),width:h("#Swiper-"+e.id).position().width});let{swipeId:o}=i.dataset;o==e.id&&c(document).addEvent({eventID:"SwipeMouseMove",eventType:"mousemove",callback:s=>{l.EffectCheck(s,e)},options:{passive:!1}}).addEvent({eventID:"SwipeTouchMove",eventType:"touchmove",callback:s=>{l.EffectCheck(s,e)},options:{passive:!1}}).addEvent({eventID:"SwipeMouseUp",eventType:"mouseup",callback:s=>{l.EffectEnd(s,e)},options:{passive:!1}}).addEvent({eventID:"SwipeTouchEnd",eventType:"touchend",callback:s=>{l.EffectEnd(s,e)},options:{passive:!1}})},EffectCheck:(t,e)=>{if(e.process)return;let{x:u,y:d}=c.getCursor(t),i=Math.abs(u-e.x+global.scrollX),r=Math.abs(d-e.y+global.scrollY);if(!(t.touches&&t.touches.length>1)&&!(r+i<15))if(r>i/2)c(document).removeEvent(["SwipeMouseMove","SwipeTouchMove"]);else{e.process=!0;let o=e.index+(e.loop?1:0);h("#Swiper-"+e.id).children(o-1).addClass(a("Display")),c(document).addEvent({eventID:"SwipeCheckMouseMove",eventType:"mousemove",callback:s=>{l.EffectMove(s,e)},options:{passive:!1}}).addEvent({eventID:"SwipeCheckTouchMove",eventType:"touchmove",callback:s=>{l.EffectMove(s,e)},options:{passive:!1}}),t.preventDefault();return}},EffectMove:(t,e)=>{if(t.touches&&t.touches.length>1)return;let{x:u}=c.getCursor(t),d=u-e.x+global.scrollX,r=e.index+(e.loop?1:0)-d/e.width;if(r<0)r/=2;else if(r>e.maxIndex){let o=r-e.maxIndex;r=e.maxIndex+o/2}h("#Swiper-"+e.id).css({transition:"0s",transform:l.TrasformString(r)}),t.preventDefault()},EffectEnd:(t,e)=>{if(e.process){let d=c.getCursor(t).x-e.x+global.scrollX,i=new Date().getTime(),r=i-e.effectStartAt,o=e.index+(e.loop?1:0),s=0;r<400?s=o-(+(d>0)*2-1):s=Math.round(o-d/e.width),s=Math.max(Math.min(s,e.maxIndex),e.minIndex),e.process=!1,o===s?(e.effectStartAt=i,h("#Swiper-"+e.id).css({transition:".2s",transform:l.TrasformString(s)}).await(310).css({transition:"0s"}).children().removeClass(a("Display")).parent().children(o).addClass(a("Display"))):e.set_event({eventType:"usr",index:s+e.minIndex})}c(document).removeEvent(["SwipeMouseMove","SwipeTouchMove","SwipeCheckMouseMove","SwipeCheckTouchMove","SwipeMouseUp","SwipeTouchEnd"])}},V=t=>g(B,T(v({},t),{slideIndex:Math.max(Math.min(t.slideIndex,t.slides.length-1),0)}));export{V as SwipeView,V as default};
@@ -96,4 +96,4 @@ Some Text`})]}),t(B.Separate,{children:[e(r.Button.Sub.S,{color:"white",onClick:
96
96
  header: ReactElement | React.FC< { modalClose } >,
97
97
  body: ReactElement | React.FC< { modalClose } >,
98
98
  footer: ReactElement | React.FC< { modalClose } >
99
- } );`})}),t(h,{padding:2,children:[e(o,{flexCenter:!0,children:t(p,{gridCols:3,gap:1,children:[e(r.Button.Border.R,{onClick:()=>{a("normal.topLeft")},children:"Top Left"}),e(r.Button.Border.R,{onClick:()=>{a("normal.topCenter")},children:"Top Center"}),e(r.Button.Border.R,{onClick:()=>{a("normal.topRight")},children:"Top Right"}),e(r.Button.Border.R,{onClick:()=>{a("normal.middleLeft")},children:"Middle Left"}),e(r.Button.Border.R,{onClick:()=>{a("normal.middleCenter")},children:"Middle Center"}),e(r.Button.Border.R,{onClick:()=>{a("normal.middleRight")},children:"Middle Right"}),e(r.Button.Border.R,{onClick:()=>{a("normal.bottomLeft")},children:"Bottom Left"}),e(r.Button.Border.R,{onClick:()=>{a("normal.bottomCenter")},children:"Bottom Center"}),e(r.Button.Border.R,{onClick:()=>{a("normal.bottomRight")},children:"Bottom Right"}),e(r.Button.Border.R,{onClick:()=>{a("drawer.left")},children:"Drawer Left"}),e(r.Button.Border.R,{onClick:()=>{a("drawer.bottom")},children:"Drawer Bottom"}),e(r.Button.Border.R,{onClick:()=>{a("drawer.right")},children:"Drawer Right"}),e(r.Button.Border.R,{onClick:u=>{F.open({tipsID:"test40",content:e(o,{padding:1,border:!0,borderRadius:2,backgroundColor:"dark",fontColor:"white",children:"Content"}),parent:u.target})},children:"Open Tooltips"})]})}),t(B.Center,{children:["Image Picker",e(T,{src:l.Images.defaultIcon("user"),unitWidth:6,unitHeight:6,showExpand:!0})]})]})]})]})},D={_:()=>e(d,{children:t(h,{children:[e(D.Data,{}),e(D.Normal,{}),e(D.Drag,{}),e(D.Spread,{})]})}),Normal:()=>{let a=[];for(var u=0;u<10;u++){let s=[{children:"head_"+u},{children:"data_"+u},{children:"data_"+u}];a.push(s)}return t(d,{children:[e(o,{fontSize:"5.subTitle",children:"Table.Normal"}),e(m.Normal,{colLength:3,head:[{children:"head1"},{children:"head2"},{children:"head3"}],rows:a,ssCardBox:!0,onRowClick:s=>{console.log(s)}})]})},Drag:()=>{let a=[];for(var u=0;u<4;u++){let s=[{children:"head_"+u},{children:"data_"+u},{children:"data_"+u}];s.rowID="rowID-"+u,a.push(s)}return t(d,{children:[e(o,{fontSize:"5.subTitle",children:"Table.Drag"}),e(m.Drag,{colLength:3,head:[{children:"head1"},{children:"head2"},{children:"head3"}],rows:a,ssCardBox:!0,onOrderChanged:s=>{console.log(s)}})]})},Data:()=>{let a=[];for(var u=0;u<100;u++){let x=Math.round(Math.random()*50+1),y=Math.round(Math.random()*50+1),A=Math.round(Math.random()*50+1),b="name_"+x,E="data_"+y,M="data_"+A,N=[{type:"th",children:u+":"+b,data:b,orderIndex:u},{type:"td",children:E,data:E},{type:"td",children:M,data:M}];a.push(N)}a[1].checked=!0,a[4].checked=!0,a[10].checked=!0;let s="testDataTable";return t(d,{children:[t(c,{horizontalAlign:"between",children:[e(o,{fontSize:"5.subTitle",children:"Table.Data"}),t(c,{gap:"1/2",backgroundColor:"theme",borderRadius:"1.tone.primary",overflow:"hidden",fontColor:"white",children:[e(r.Button.Clear.R,{color:"white",children:"SubmitButton"}),e(o,{flexSizing:"none",unitWidth:"1/4",backgroundColor:"layer.4.opa.middle",isRounded:!0,margin:["2/3",0]}),e(r.Button.Clear.R,{padding:[0,1],color:"white",onClick:x=>{F.open({tipsID:w.uuid.gen(),parent:x.target,gravityPoint:24,close_option:{aroundClick:!0,parentBlur:!1},content:e(d,{children:t(h,{gap:0,padding:["2/3",0],backgroundColor:"layer.1",borderRadius:2,boxShadow:"0.normal",overflow:"hidden",children:[e(r.Button.Clear.S,{borderRadius:0,borderBottom:"1.thin",children:"\u3059\u3079\u3066\u3092\u51FA\u529B"}),e(r.Button.Clear.S,{borderRadius:0,borderBottom:"1.thin",children:"\u3053\u306E\u30DA\u30FC\u30B8\u306E\u307F\u51FA\u529B"}),e(r.Button.Clear.S,{borderRadius:0,children:"\u30C1\u30A7\u30C3\u30AF\u3057\u305F\u884C\u306E\u307F\u51FA\u529B"})]})})})},children:e(g.EllipsisV,{})})]})]}),t(B.Separate,{verticalAlign:"bottom",children:[t(B.Left,{verticalAlign:"bottom",children:[e(m.Data.SearchInput,{tableID:s}),e(m.Data.Info,{tableID:s})]}),t(B.Right,{verticalAlign:"unset",children:[e(m.Data.RowLength,{tableID:s,lengthSelect:[30,50,100]}),e(m.Data.Paging,{tableID:s})]})]}),e(m.Data,{tableID:s,colLength:3,head:[{data:"head1"},{data:"head2"},{data:"head3"}],rows:a,pageRowLength:30,ssCardBox:!0,filter:[!0],checker:!0})]})},Spread:()=>e(d,{children:e(o,{fontSize:"5.subTitle",children:"Table.Spread"})})},X=()=>{let[a,u]=S.useState(""),[s,x]=S.useState(""),[y,A]=S.useState("");return e(d,{children:t(o,{children:[t(r.Button.Prime.R,{onClick:()=>{J.open({use:"square",develops:[{size:"S"},{size:"R"},{size:"L"}],onProcessFinished:b=>I(void 0,null,function*(){u(yield b[0].toDataUrl()),x(yield b[1].toDataUrl()),A(yield b[2].toDataUrl())})})},children:[e(g.Image,{})," \u30A4\u30E1\u30FC\u30B8\u3092\u9078\u629E"]}),t(c,{verticalAlign:"top",gap:1,children:[a&&e(T,{isRounded:!0,src:a,alt:"",showExpand:!0,freeCSS:{maxWidth:12*12}}),s&&e(T,{style:{maxWidth:24*12},src:s,alt:"",showExpand:!0}),y&&e(T,{style:{maxWidth:24*12},src:y,alt:"",showExpand:!0}),e(k.SwipeView,{border:!0,borderWidth:3,margin:[3,"auto"],freeCSS:{width:12*10},slideIndex:1,options:{loop:!0,onSlideCallback:b=>{}},slides:[e(o,{backgroundColor:"nega",padding:3,flexCenter:!0,children:"test1"}),e(o,{backgroundColor:"posi",padding:3,flexCenter:!0,children:"test2"}),e(o,{backgroundColor:"warn",padding:3,flexCenter:!0,children:"test3"}),e(o,{backgroundColor:"theme",padding:3,flexCenter:!0,children:"test4"})]})]})]})})},_=()=>{let[a,u]=S.useState(Number(w.queryParams.get().ti)||0);return S.useEffect(()=>{w.queryParams.set({key:"ti",value:a})},[a]),t(h,{padding:2,children:[e(i.Time.Clock,{value:"15:30"}),e(i.Time.Clock,{})]});return e(d,{children:t(h,{gap:0,minHeight:"contentHeight",backgroundColor:"layer.1",children:[e(k.TabBar,{borderBottom:!0,position:"sticky",backgroundColor:"layer.1",top:"topBase",tabIndex:a,tabs:["Profiles","Basic","Buttons","Inputs","Styling","Effection","Tables","Croppie","PlayGround","Logo"],onTabChange:s=>{localStorage.setItem("designTabHeader",String(s)),u(s)},UnderBreakPointStyles:{position:"static",top:0}}),e(o,{flexSizing:0,position:"relative",freeCSS:{zIndex:1},children:e(k.PageViewController,{viewIndex:a,views:[e(W._,{}),e(R._,{}),e(P._,{}),e(K,{}),e(j,{}),e(L._,{}),e(D._,{}),e(X,{}),e(f._,{})],wrapper:s=>e(Y.FadeIn,{animationTime:200,children:e(k.Plate,{children:e(c,{gap:2,padding:2,flexWrap:!0,flexChilds:"auto",children:s})})},a)})})]})})};export{_ as DesignBook,_ as default};
99
+ } );`})}),t(h,{padding:2,children:[e(o,{flexCenter:!0,children:t(p,{gridCols:3,gap:1,children:[e(r.Button.Border.R,{onClick:()=>{a("normal.topLeft")},children:"Top Left"}),e(r.Button.Border.R,{onClick:()=>{a("normal.topCenter")},children:"Top Center"}),e(r.Button.Border.R,{onClick:()=>{a("normal.topRight")},children:"Top Right"}),e(r.Button.Border.R,{onClick:()=>{a("normal.middleLeft")},children:"Middle Left"}),e(r.Button.Border.R,{onClick:()=>{a("normal.middleCenter")},children:"Middle Center"}),e(r.Button.Border.R,{onClick:()=>{a("normal.middleRight")},children:"Middle Right"}),e(r.Button.Border.R,{onClick:()=>{a("normal.bottomLeft")},children:"Bottom Left"}),e(r.Button.Border.R,{onClick:()=>{a("normal.bottomCenter")},children:"Bottom Center"}),e(r.Button.Border.R,{onClick:()=>{a("normal.bottomRight")},children:"Bottom Right"}),e(r.Button.Border.R,{onClick:()=>{a("drawer.left")},children:"Drawer Left"}),e(r.Button.Border.R,{onClick:()=>{a("drawer.bottom")},children:"Drawer Bottom"}),e(r.Button.Border.R,{onClick:()=>{a("drawer.right")},children:"Drawer Right"}),e(r.Button.Border.R,{onClick:u=>{F.open({tipsID:"test40",content:e(o,{padding:1,border:!0,borderRadius:2,backgroundColor:"dark",fontColor:"white",children:"Content"}),parent:u.target})},children:"Open Tooltips"})]})}),t(B.Center,{children:["Image Picker",e(T,{src:l.Images.defaultIcon("user"),unitWidth:6,unitHeight:6,showExpand:!0})]})]})]})]})},D={_:()=>e(d,{children:t(h,{children:[e(D.Data,{}),e(D.Normal,{}),e(D.Drag,{}),e(D.Spread,{})]})}),Normal:()=>{let a=[];for(var u=0;u<10;u++){let s=[{children:"head_"+u},{children:"data_"+u},{children:"data_"+u}];a.push(s)}return t(d,{children:[e(o,{fontSize:"5.subTitle",children:"Table.Normal"}),e(m.Normal,{colLength:3,head:[{children:"head1"},{children:"head2"},{children:"head3"}],rows:a,ssCardBox:!0,onRowClick:s=>{console.log(s)}})]})},Drag:()=>{let a=[];for(var u=0;u<4;u++){let s=[{children:"head_"+u},{children:"data_"+u},{children:"data_"+u}];s.rowID="rowID-"+u,a.push(s)}return t(d,{children:[e(o,{fontSize:"5.subTitle",children:"Table.Drag"}),e(m.Drag,{colLength:3,head:[{children:"head1"},{children:"head2"},{children:"head3"}],rows:a,ssCardBox:!0,onOrderChanged:s=>{console.log(s)}})]})},Data:()=>{let a=[];for(var u=0;u<100;u++){let x=Math.round(Math.random()*50+1),y=Math.round(Math.random()*50+1),A=Math.round(Math.random()*50+1),b="name_"+x,E="data_"+y,M="data_"+A,N=[{type:"th",children:u+":"+b,data:b,orderIndex:u},{type:"td",children:E,data:E},{type:"td",children:M,data:M}];a.push(N)}a[1].checked=!0,a[4].checked=!0,a[10].checked=!0;let s="testDataTable";return t(d,{children:[t(c,{horizontalAlign:"between",children:[e(o,{fontSize:"5.subTitle",children:"Table.Data"}),t(c,{gap:"1/2",backgroundColor:"theme",borderRadius:"1.tone.primary",overflow:"hidden",fontColor:"white",children:[e(r.Button.Clear.R,{color:"white",children:"SubmitButton"}),e(o,{flexSizing:"none",unitWidth:"1/4",backgroundColor:"layer.4.opa.middle",isRounded:!0,margin:["2/3",0]}),e(r.Button.Clear.R,{padding:[0,1],color:"white",onClick:x=>{F.open({tipsID:w.uuid.gen(),parent:x.target,gravityPoint:24,close_option:{aroundClick:!0,parentBlur:!1},content:e(d,{children:t(h,{gap:0,padding:["2/3",0],backgroundColor:"layer.1",borderRadius:2,boxShadow:"0.normal",overflow:"hidden",children:[e(r.Button.Clear.S,{borderRadius:0,borderBottom:"1.thin",children:"\u3059\u3079\u3066\u3092\u51FA\u529B"}),e(r.Button.Clear.S,{borderRadius:0,borderBottom:"1.thin",children:"\u3053\u306E\u30DA\u30FC\u30B8\u306E\u307F\u51FA\u529B"}),e(r.Button.Clear.S,{borderRadius:0,children:"\u30C1\u30A7\u30C3\u30AF\u3057\u305F\u884C\u306E\u307F\u51FA\u529B"})]})})})},children:e(g.EllipsisV,{})})]})]}),t(B.Separate,{verticalAlign:"bottom",children:[t(B.Left,{verticalAlign:"bottom",children:[e(m.Data.SearchInput,{tableID:s}),e(m.Data.Info,{tableID:s})]}),t(B.Right,{verticalAlign:"unset",children:[e(m.Data.RowLength,{tableID:s,lengthSelect:[30,50,100]}),e(m.Data.Paging,{tableID:s})]})]}),e(m.Data,{tableID:s,colLength:3,head:[{data:"head1"},{data:"head2"},{data:"head3"}],rows:a,pageRowLength:30,ssCardBox:!0,filter:[!0],checker:!0})]})},Spread:()=>e(d,{children:e(o,{fontSize:"5.subTitle",children:"Table.Spread"})})},X=()=>{let[a,u]=S.useState(""),[s,x]=S.useState(""),[y,A]=S.useState("");return e(d,{children:t(o,{children:[t(r.Button.Prime.R,{onClick:()=>{J.open({use:"square",develops:[{size:"S"},{size:"R"},{size:"L"}],onProcessFinished:b=>I(void 0,null,function*(){u(yield b[0].toDataUrl()),x(yield b[1].toDataUrl()),A(yield b[2].toDataUrl())})})},children:[e(g.Image,{})," \u30A4\u30E1\u30FC\u30B8\u3092\u9078\u629E"]}),t(c,{verticalAlign:"top",gap:1,children:[a&&e(T,{isRounded:!0,src:a,alt:"",showExpand:!0,freeCSS:{maxWidth:12*12}}),s&&e(T,{style:{maxWidth:24*12},src:s,alt:"",showExpand:!0}),y&&e(T,{style:{maxWidth:24*12},src:y,alt:"",showExpand:!0}),e(k.SwipeView,{border:!0,borderWidth:3,margin:[3,"auto"],freeCSS:{width:12*10},slideIndex:1,options:{loop:!0,onSlideCallback:b=>{}},slides:[e(o,{backgroundColor:"nega",padding:3,flexCenter:!0,children:"test1"}),e(o,{backgroundColor:"posi",padding:3,flexCenter:!0,children:"test2"}),e(o,{backgroundColor:"warn",padding:3,flexCenter:!0,children:"test3"}),e(o,{backgroundColor:"theme",padding:3,flexCenter:!0,children:"test4"})]})]})]})})},_=()=>{let[a,u]=S.useState(Number(w.queryParams.get().ti)||0);return S.useEffect(()=>{w.queryParams.set({key:"ti",value:a})},[a]),e(d,{children:t(h,{gap:0,minHeight:"contentHeight",backgroundColor:"layer.1",children:[e(k.TabBar,{borderBottom:!0,position:"sticky",backgroundColor:"layer.1",top:"topBase",tabIndex:a,tabs:["Profiles","Basic","Buttons","Inputs","Styling","Effection","Tables","Croppie","PlayGround","Logo"],onTabChange:s=>{localStorage.setItem("designTabHeader",String(s)),u(s)},UnderBreakPointStyles:{position:"static",top:0}}),e(o,{flexSizing:0,position:"relative",freeCSS:{zIndex:1},children:e(k.PageViewController,{viewIndex:a,views:[e(W._,{}),e(R._,{}),e(P._,{}),e(K,{}),e(j,{}),e(L._,{}),e(D._,{}),e(X,{}),e(f._,{})],wrapper:s=>e(Y.FadeIn,{animationTime:200,children:e(k.Plate,{children:e(c,{gap:2,padding:2,flexWrap:!0,flexChilds:"auto",children:s})})},a)})})]})})};export{_ as DesignBook,_ as default};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "amotify",
3
- "version": "0.1.54",
3
+ "version": "0.1.56",
4
4
  "description": "UI FW for React",
5
5
  "scripts": {
6
6
  "clean": "rimraf dist",