react-restyle-components 0.4.38 → 0.4.39
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.
- package/lib/src/core-components/src/utils/stories/Wrappers.d.ts +12 -0
- package/lib/src/core-components/src/utils/stories/Wrappers.js +32 -0
- package/lib/src/core-components/src/utils/stories/cleanProps.d.ts +1 -0
- package/lib/src/core-components/src/utils/stories/cleanProps.js +1 -0
- package/lib/src/core-components/src/utils/stories/index.d.ts +4 -0
- package/lib/src/core-components/src/utils/stories/index.js +1 -0
- package/lib/src/core-components/src/utils/stories/sleep.d.ts +1 -0
- package/lib/src/core-components/src/utils/stories/sleep.js +1 -0
- package/lib/src/core-components/src/utils/stories/view-ports.d.ts +50 -0
- package/lib/src/core-components/src/utils/stories/view-ports.js +1 -0
- package/lib/src/core-components/src/utils/testing/getComputedStyle.d.ts +1 -0
- package/lib/src/core-components/src/utils/testing/getComputedStyle.js +1 -0
- package/lib/src/core-components/src/utils/testing/index.d.ts +1 -0
- package/lib/src/core-components/src/utils/testing/index.js +1 -0
- package/lib/src/core-components/tailwind.config.js +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export declare const Wrappers: {
|
|
3
|
+
Default: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
4
|
+
Dashed: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
|
|
5
|
+
$width?: string | undefined;
|
|
6
|
+
}>> & string;
|
|
7
|
+
TextInput: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
8
|
+
Modal: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
9
|
+
Row: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
10
|
+
Test: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
11
|
+
};
|
|
12
|
+
export declare const Decorators: Record<"Default" | "Dashed" | "TextInput" | "Modal" | "Row" | "Test", (Story: React.ComponentType) => React.JSX.Element>;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";import{jsx as r}from"react/jsx-runtime";import{styled as e}from"styled-components";export const Wrappers={Default:e.div`
|
|
2
|
+
display: flex;
|
|
3
|
+
justify-content: flex-start;
|
|
4
|
+
padding: 2rem;
|
|
5
|
+
`,Dashed:e.div`
|
|
6
|
+
margin: auto;
|
|
7
|
+
${({$width:i})=>i&&`width: ${i};`}
|
|
8
|
+
border: 2px dashed var(--aui-primary);
|
|
9
|
+
border-radius: 8px;
|
|
10
|
+
padding: 8px;
|
|
11
|
+
`,TextInput:e.div`
|
|
12
|
+
width: 250px;
|
|
13
|
+
display: flex;
|
|
14
|
+
flex-direction: column;
|
|
15
|
+
gap: 1rem;
|
|
16
|
+
margin: auto;
|
|
17
|
+
`,Modal:e.div`
|
|
18
|
+
height: 100%;
|
|
19
|
+
margin: -1rem;
|
|
20
|
+
`,Row:e.div`
|
|
21
|
+
max-width: 100%;
|
|
22
|
+
flex-wrap: wrap;
|
|
23
|
+
display: flex;
|
|
24
|
+
gap: 10px;
|
|
25
|
+
align-items: center;
|
|
26
|
+
justify-content: center;
|
|
27
|
+
`,Test:e.div`
|
|
28
|
+
display: flex;
|
|
29
|
+
flex-direction: column;
|
|
30
|
+
gap: 1rem;
|
|
31
|
+
width: min(100%, 600px);
|
|
32
|
+
`},Decorators=Object.entries(Wrappers).reduce((i,[t,a])=>({...i,[t]:d=>r(a,{children:r(d,{})})}),{});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function cleanProps<T extends Record<string, unknown>>(object: T): T | undefined;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";export function cleanProps(n){return Object.entries(n).filter(([,e])=>e!==void 0).reduce((e,[r,t])=>({...e,[r]:t}),{})}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";export*from"./view-ports";export*from"./cleanProps";export*from"./sleep";export*from"./Wrappers";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function sleep(ms: number): Promise<unknown>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";export async function sleep(e){return new Promise(n=>setTimeout(n,e))}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
export declare const VIEWPORTS: {
|
|
2
|
+
sm: {
|
|
3
|
+
name: string;
|
|
4
|
+
styles: {
|
|
5
|
+
height: string;
|
|
6
|
+
width: string;
|
|
7
|
+
};
|
|
8
|
+
type: string;
|
|
9
|
+
};
|
|
10
|
+
md: {
|
|
11
|
+
name: string;
|
|
12
|
+
styles: {
|
|
13
|
+
height: string;
|
|
14
|
+
width: string;
|
|
15
|
+
};
|
|
16
|
+
type: string;
|
|
17
|
+
};
|
|
18
|
+
md2: {
|
|
19
|
+
name: string;
|
|
20
|
+
styles: {
|
|
21
|
+
height: string;
|
|
22
|
+
width: string;
|
|
23
|
+
};
|
|
24
|
+
type: string;
|
|
25
|
+
};
|
|
26
|
+
lg: {
|
|
27
|
+
name: string;
|
|
28
|
+
styles: {
|
|
29
|
+
height: string;
|
|
30
|
+
width: string;
|
|
31
|
+
};
|
|
32
|
+
type: string;
|
|
33
|
+
};
|
|
34
|
+
xl: {
|
|
35
|
+
name: string;
|
|
36
|
+
styles: {
|
|
37
|
+
height: string;
|
|
38
|
+
width: string;
|
|
39
|
+
};
|
|
40
|
+
type: string;
|
|
41
|
+
};
|
|
42
|
+
xxl: {
|
|
43
|
+
name: string;
|
|
44
|
+
styles: {
|
|
45
|
+
height: string;
|
|
46
|
+
width: string;
|
|
47
|
+
};
|
|
48
|
+
type: string;
|
|
49
|
+
};
|
|
50
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";export const VIEWPORTS={sm:{name:"SM",styles:{height:"100%",width:"375px"},type:"mobile"},md:{name:"MD",styles:{height:"100%",width:"768px"},type:"mobile"},md2:{name:"MD2",styles:{height:"100%",width:"1024px"},type:"mobile"},lg:{name:"LG",styles:{height:"100%",width:"1280px"},type:"mobile"},xl:{name:"XL",styles:{height:"100%",width:"1440px"},type:"mobile"},xxl:{name:"XXL",styles:{height:"100%",width:"1920px"},type:"mobile"}};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function getComputedStyle(element: HTMLElement, property: string): any;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";export function getComputedStyle(t,e){return window.getComputedStyle(t)[e]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './getComputedStyle';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";export*from"./getComputedStyle";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const defaultTheme=require("tailwindcss/defaultTheme");module.exports={content:["./public/**/*.html","./src/**/*.{js,jsx,ts,tsx,vue}"],darkMode:"class",theme:{extend:{screens:{...defaultTheme.screens,sm:{min:"0px",max:"767px"},md:{min:"768px",max:"2000px"},"token-xs":"20rem","token-sm":"23.4375rem","token-md":"48rem","token-lg":"64rem","token-xl":"80rem","token-xxl":"90rem"},colors:{current:"currentColor",transparent:"transparent","text-base":"#ffffff",primary:"#454cbf",secondary:"#c57c85",accent:"#422a68",black:"#000000",grey:"#6A727F",grey_0:"#4a4a4a",grey_1:"#707070",light_1:"#ebebeb",white:"#ffffff",background:"#ffffff",light_white:"#f4f6f6",red:{DEFAULT:"#ff0000",...defaultTheme.colors.red},orange:"#ffae1a",mono:"#754c00","border-red":"#ff0000",bgGrey:"#808080",stroke:"#E2E8F0",boxdark:"#24303F","boxdark-2":"#1A222C",strokedark:"#2E3A47",content:"#000000","form-strokedark":"#3d4d60","form-input":"#1d2a39","meta-1":"#DC3545","meta-2":"#EFF2F7","meta-3":"#10B981","meta-4":"#313D4A","meta-5":"#259AE6","meta-6":"#FFBA00","meta-7":"#FF6766","meta-8":"#F0950C","meta-9":"#E5E7EB",success:"#219653",danger:"#D34053",warning:"#FFA70B","token-surface":"var(--surface)","token-on-surface":"var(--on-surface)","token-primary":"var(--primary)","token-on-primary":"var(--on-primary)","token-outline":"var(--outline)","token-outline-soft":"var(--outline-soft)","token-success":"var(--status-success)","token-error":"var(--status-error)","token-warning":"var(--status-warning)"},fontFamily:{arimaRegular:["ArimaRegular"]},fontSize:{"title-xxl":["44px","55px"],"title-xl":["36px","45px"],"title-xl2":["33px","45px"],"title-lg":["28px","35px"],"title-md":["24px","30px"],"title-md2":["26px","30px"],"title-sm":["20px","26px"],"title-xsm":["18px","24px"]},spacing:{"8xl":"96rem","9xl":"128rem","token-000":"0rem","token-025":"0.125rem","token-050":"0.25rem","token-075":"0.375rem","token-100":"0.5rem","token-150":"0.75rem","token-200":"1rem","token-300":"1.5rem","token-400":"2rem","token-500":"2.5rem","token-600":"3rem","token-800":"4rem","token-1000":"5rem","token-1200":"6rem"},borderRadius:{"4xl":"2rem","100px":"100px","token-025":"0.125rem","token-050":"0.25rem","token-100":"0.5rem","token-200":"1rem","token-300":"1.5rem","token-400":"2rem","token-none":"0rem","token-round":"10000rem"},height:{"screen/2":"50vh",screen98:"98vh",screen96:"96vh",screen94:"94vh",screen92:"92vh","screen/3":"calc(100vh / 3)","screen/4":"calc(100vh / 4)","screen/5":"calc(100vh / 5)"},zIndex:{999999:"999999",99999:"99999",9999:"9999",999:"999",99:"99",9:"9",1:"1"},transitionProperty:{width:"width",stroke:"stroke"},borderWidth:{6:"6px"},opacity:{"token-04":"4%","token-08":"8%","token-10":"10%","token-12":"12%","token-20":"20%","token-30":"30%","token-40":"40%","token-50":"50%","token-60":"60%","token-70":"70%","token-75":"75%","token-80":"80%","token-90":"90%","token-100":"100%","token-none":"0%"},strokeWidth:{"token-card":"0.0625rem","token-selected-card-hover":"0.125rem","token-divider":"0.0625rem"},boxShadow:{default:"0px 8px 13px -3px rgba(0, 0, 0, 0.07)",card:"0px 1px 3px rgba(0, 0, 0, 0.12)","card-2":"0px 1px 2px rgba(0, 0, 0, 0.05)",switcher:"0px 2px 4px rgba(0, 0, 0, 0.2), inset 0px 2px 2px #FFFFFF, inset 0px -1px 1px rgba(0, 0, 0, 0.1)","switch-1":"0px 0px 5px rgba(0, 0, 0, 0.15)",1:"0px 1px 3px rgba(0, 0, 0, 0.08)",2:"0px 1px 4px rgba(0, 0, 0, 0.12)",3:"0px 1px 5px rgba(0, 0, 0, 0.14)",4:"0px 4px 10px rgba(0, 0, 0, 0.12)",5:"0px 1px 1px rgba(0, 0, 0, 0.15)",6:"0px 3px 15px rgba(0, 0, 0, 0.1)",7:"-5px 0 0 #313D4A, 5px 0 0 #313D4A",8:"1px 0 0 #313D4A, -1px 0 0 #313D4A, 0 1px 0 #313D4A, 0 -1px 0 #313D4A, 0 3px 13px rgb(0 0 0 / 8%)"},dropShadow:{1:"0px 1px 0px #E2E8F0",2:"0px 1px 4px rgba(0, 0, 0, 0.12)"},keyframes:{rotating:{"0%, 100%":{transform:"rotate(360deg)"},"50%":{transform:"rotate(0deg)"}},flip:{to:{transform:"rotate(360deg)"}},rotate:{to:{transform:"rotate(90deg)"}}},animation:{"ping-once":"ping 5s cubic-bezier(0, 0, 0.2, 1)",rotating:"rotating 30s linear infinite","spin-1.5":"spin 1.5s linear infinite","spin-2":"spin 2s linear infinite","spin-3":"spin 3s linear infinite",flip:"flip 6s infinite steps(2, end)",rotate:"rotate 3s linear infinite both"}},borderWidth:{DEFAULT:"1px"}},styles:{colors:{lightBack:""}},variants:{extend:{opacity:["disabled"],cursor:["disabled"],borderRadius:["hover","first","last"],zIndex:["hover"],borderCollapse:["hover","focus"]}},corePlugins:{tableLayout:!1}};
|