lupine.components 1.1.13 → 1.1.14
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/README.md +3 -3
- package/package.json +42 -42
- package/src/components/action-sheet.tsx +419 -419
- package/src/components/button-push-animation.tsx +147 -138
- package/src/components/button.tsx +55 -55
- package/src/components/desktop-footer.tsx +17 -17
- package/src/components/desktop-header.tsx +52 -52
- package/src/components/drag-refresh.tsx +129 -129
- package/src/components/editable-label.tsx +83 -83
- package/src/components/float-window.tsx +233 -233
- package/src/components/grid.tsx +18 -18
- package/src/components/html-load.tsx +41 -41
- package/src/components/html-var.tsx +81 -81
- package/src/components/index.ts +43 -44
- package/src/components/input-with-title.tsx +24 -24
- package/src/components/link-item.tsx +13 -13
- package/src/components/link-list.tsx +62 -62
- package/src/components/menu-bar.tsx +219 -219
- package/src/components/menu-item-props.tsx +13 -13
- package/src/components/menu-sidebar.tsx +325 -318
- package/src/components/message-box.tsx +44 -44
- package/src/components/meta-data.tsx +36 -36
- package/src/components/meta-description.tsx +12 -12
- package/src/components/mobile-components/icon-menu-item-props.ts +6 -6
- package/src/components/mobile-components/index.ts +8 -9
- package/src/components/mobile-components/mobile-footer-menu.tsx +95 -95
- package/src/components/mobile-components/mobile-header-component.tsx +101 -101
- package/src/components/mobile-components/mobile-header-title-icon.tsx +109 -101
- package/src/components/mobile-components/mobile-header-with-back.tsx +127 -117
- package/src/components/mobile-components/mobile-side-menu.tsx +154 -154
- package/src/components/mobile-components/mobile-top-sys-icon.tsx +18 -18
- package/src/components/mobile-components/mobile-top-sys-menu.tsx +62 -62
- package/src/components/modal.tsx +33 -33
- package/src/components/notice-message.tsx +118 -118
- package/src/components/page-title.tsx +6 -6
- package/src/components/paging-link.tsx +175 -175
- package/src/components/panel.tsx +21 -21
- package/src/components/popup-menu.tsx +289 -289
- package/src/components/progress.tsx +91 -91
- package/src/components/radio-label-component.tsx +36 -36
- package/src/components/redirect.tsx +19 -19
- package/src/components/resizable-splitter.tsx +128 -128
- package/src/components/select-angle-component.tsx +127 -127
- package/src/components/select-with-title.tsx +37 -37
- package/src/components/slide-tab-component.tsx +144 -149
- package/src/components/spinner.tsx +106 -100
- package/src/components/stars-component.tsx +66 -66
- package/src/components/svg.tsx +24 -24
- package/src/components/tabs.tsx +279 -279
- package/src/components/text-glow.tsx +37 -37
- package/src/components/text-scale.tsx +42 -42
- package/src/components/text-wave.tsx +55 -55
- package/src/components/theme-selector.tsx +28 -28
- package/src/components/toggle-base.tsx +269 -269
- package/src/components/toggle-switch.tsx +160 -160
- package/src/frames/index.ts +3 -3
- package/src/frames/responsive-frame.tsx +83 -83
- package/src/frames/slider-frame.tsx +111 -111
- package/src/frames/top-frame.tsx +30 -30
- package/src/index.ts +5 -5
- package/src/lib/back-action-helper.ts +54 -54
- package/src/lib/base62.ts +23 -23
- package/src/lib/blob-utils.ts +23 -23
- package/src/lib/calculate-text-width.ts +13 -13
- package/src/lib/date-utils.ts +317 -317
- package/src/lib/deep-merge.ts +37 -37
- package/src/lib/document-ready.ts +34 -34
- package/src/lib/dom-utils.ts +32 -32
- package/src/lib/download-file.ts +118 -118
- package/src/lib/download-link.ts +12 -12
- package/src/lib/download-stream.ts +19 -19
- package/src/lib/drag-util.ts +118 -118
- package/src/lib/dynamical-load.ts +134 -134
- package/src/lib/encode-html.ts +27 -27
- package/src/lib/find-parent-tag.ts +8 -8
- package/src/lib/format-bytes.ts +11 -11
- package/src/lib/index.ts +24 -24
- package/src/lib/lite-dom.ts +225 -225
- package/src/lib/message-hub.ts +103 -104
- package/src/lib/observable.ts +188 -188
- package/src/lib/path-utils.ts +42 -42
- package/src/lib/promise-timeout.ts +1 -1
- package/src/lib/simple-storage.ts +40 -40
- package/src/lib/stop-propagation.ts +7 -7
- package/src/lib/upload-file.ts +101 -101
- package/src/styles/base-themes.ts +17 -17
- package/src/styles/dark-themes.ts +99 -99
- package/src/styles/index.ts +5 -5
- package/src/styles/light-themes.ts +106 -106
- package/src/styles/media-query.ts +93 -93
- package/src/styles/shared-themes.ts +57 -57
- package/tsconfig.json +113 -113
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
import { bindGlobalStyle, CssProps } from 'lupine.web';
|
|
2
|
-
|
|
3
|
-
export type TextScaleProps = {
|
|
4
|
-
text: string;
|
|
5
|
-
color?: string;
|
|
6
|
-
backgroundColor?: string;
|
|
7
|
-
padding?: string;
|
|
8
|
-
fontSize?: string;
|
|
9
|
-
fontWeight?: string;
|
|
10
|
-
};
|
|
11
|
-
export const TextScale = (props: TextScaleProps) => {
|
|
12
|
-
const css: CssProps = {
|
|
13
|
-
width: `100%`,
|
|
14
|
-
height: `100%`,
|
|
15
|
-
display: 'flex',
|
|
16
|
-
justifyContent: 'center',
|
|
17
|
-
alignItems: 'center',
|
|
18
|
-
color: props.color || '#22b8ff',
|
|
19
|
-
fontSize: props.fontSize || '30px',
|
|
20
|
-
fontWeight: props.fontWeight || '500',
|
|
21
|
-
'.text-scale': {
|
|
22
|
-
animation: 'text-scale 1.5s infinite alternate',
|
|
23
|
-
backgroundColor: props.backgroundColor || '#a1ffe8',
|
|
24
|
-
padding: props.padding || '10px',
|
|
25
|
-
borderRadius: '5px',
|
|
26
|
-
},
|
|
27
|
-
'@keyframes text-scale': {
|
|
28
|
-
'0%, 100%': {
|
|
29
|
-
transform: 'scale(1)',
|
|
30
|
-
},
|
|
31
|
-
'40%': {
|
|
32
|
-
transform: 'scale(0.7)',
|
|
33
|
-
},
|
|
34
|
-
},
|
|
35
|
-
};
|
|
36
|
-
bindGlobalStyle('text-scale-top', css);
|
|
37
|
-
return (
|
|
38
|
-
<div class='text-scale-top'>
|
|
39
|
-
<div class='text-scale'>{props.text}</div>
|
|
40
|
-
</div>
|
|
41
|
-
);
|
|
42
|
-
};
|
|
1
|
+
import { bindGlobalStyle, CssProps } from 'lupine.web';
|
|
2
|
+
|
|
3
|
+
export type TextScaleProps = {
|
|
4
|
+
text: string;
|
|
5
|
+
color?: string;
|
|
6
|
+
backgroundColor?: string;
|
|
7
|
+
padding?: string;
|
|
8
|
+
fontSize?: string;
|
|
9
|
+
fontWeight?: string;
|
|
10
|
+
};
|
|
11
|
+
export const TextScale = (props: TextScaleProps) => {
|
|
12
|
+
const css: CssProps = {
|
|
13
|
+
width: `100%`,
|
|
14
|
+
height: `100%`,
|
|
15
|
+
display: 'flex',
|
|
16
|
+
justifyContent: 'center',
|
|
17
|
+
alignItems: 'center',
|
|
18
|
+
color: props.color || '#22b8ff',
|
|
19
|
+
fontSize: props.fontSize || '30px',
|
|
20
|
+
fontWeight: props.fontWeight || '500',
|
|
21
|
+
'.text-scale': {
|
|
22
|
+
animation: 'text-scale 1.5s infinite alternate',
|
|
23
|
+
backgroundColor: props.backgroundColor || '#a1ffe8',
|
|
24
|
+
padding: props.padding || '10px',
|
|
25
|
+
borderRadius: '5px',
|
|
26
|
+
},
|
|
27
|
+
'@keyframes text-scale': {
|
|
28
|
+
'0%, 100%': {
|
|
29
|
+
transform: 'scale(1)',
|
|
30
|
+
},
|
|
31
|
+
'40%': {
|
|
32
|
+
transform: 'scale(0.7)',
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
};
|
|
36
|
+
bindGlobalStyle('text-scale-top', css);
|
|
37
|
+
return (
|
|
38
|
+
<div class='text-scale-top'>
|
|
39
|
+
<div class='text-scale'>{props.text}</div>
|
|
40
|
+
</div>
|
|
41
|
+
);
|
|
42
|
+
};
|
|
@@ -1,55 +1,55 @@
|
|
|
1
|
-
import { bindGlobalStyle, CssProps } from
|
|
2
|
-
|
|
3
|
-
export type TextLoadingProps = {
|
|
4
|
-
text: string;
|
|
5
|
-
color?: string;
|
|
6
|
-
padding?: string;
|
|
7
|
-
fontSize?: string;
|
|
8
|
-
fontWeight?: string;
|
|
9
|
-
};
|
|
10
|
-
export const TextWave = (props: TextLoadingProps) => {
|
|
11
|
-
const cssMap: CssProps = {};
|
|
12
|
-
props.text.split('').forEach((char, index) => {
|
|
13
|
-
cssMap[`.span${index}`] = { animationDelay: `${index * 0.1}s` };
|
|
14
|
-
});
|
|
15
|
-
const css: CssProps = {
|
|
16
|
-
width: `100%`,
|
|
17
|
-
height: `100%`,
|
|
18
|
-
textAlign: 'center',
|
|
19
|
-
color: props.color || '#22b8ff',
|
|
20
|
-
padding: props.padding || '10px',
|
|
21
|
-
fontSize: props.fontSize || '20px',
|
|
22
|
-
fontWeight: props.fontWeight,
|
|
23
|
-
textShadow: '1px -1px #ffffff, -2px 2px #999, -6px 7px 3px #131f5be6',
|
|
24
|
-
'.text-wave.wave-animetion span': {
|
|
25
|
-
display: 'inline-block',
|
|
26
|
-
padding: '0 4px',
|
|
27
|
-
animation: 'wave-text 1s ease-in-out infinite',
|
|
28
|
-
},
|
|
29
|
-
'.text-wave.wave-animetion': {
|
|
30
|
-
marginTop: '0.6em',
|
|
31
|
-
...cssMap,
|
|
32
|
-
},
|
|
33
|
-
'@keyframes wave-text': {
|
|
34
|
-
'0%': {
|
|
35
|
-
transform: 'translateY(0em)',
|
|
36
|
-
},
|
|
37
|
-
'60%': {
|
|
38
|
-
transform: 'translateY(-0.6em)',
|
|
39
|
-
},
|
|
40
|
-
'100%': {
|
|
41
|
-
transform: 'translateY(0em)',
|
|
42
|
-
},
|
|
43
|
-
},
|
|
44
|
-
};
|
|
45
|
-
bindGlobalStyle('text-wave-top', css);
|
|
46
|
-
return (
|
|
47
|
-
<div class='text-wave-top'>
|
|
48
|
-
<div class='text-wave wave-animetion'>
|
|
49
|
-
{props.text.split('').map((char, index) => (
|
|
50
|
-
<span class={`span${index}`}>{char}</span>
|
|
51
|
-
))}
|
|
52
|
-
</div>
|
|
53
|
-
</div>
|
|
54
|
-
);
|
|
55
|
-
};
|
|
1
|
+
import { bindGlobalStyle, CssProps } from 'lupine.web';
|
|
2
|
+
|
|
3
|
+
export type TextLoadingProps = {
|
|
4
|
+
text: string;
|
|
5
|
+
color?: string;
|
|
6
|
+
padding?: string;
|
|
7
|
+
fontSize?: string;
|
|
8
|
+
fontWeight?: string;
|
|
9
|
+
};
|
|
10
|
+
export const TextWave = (props: TextLoadingProps) => {
|
|
11
|
+
const cssMap: CssProps = {};
|
|
12
|
+
props.text.split('').forEach((char, index) => {
|
|
13
|
+
cssMap[`.span${index}`] = { animationDelay: `${index * 0.1}s` };
|
|
14
|
+
});
|
|
15
|
+
const css: CssProps = {
|
|
16
|
+
width: `100%`,
|
|
17
|
+
height: `100%`,
|
|
18
|
+
textAlign: 'center',
|
|
19
|
+
color: props.color || '#22b8ff',
|
|
20
|
+
padding: props.padding || '10px',
|
|
21
|
+
fontSize: props.fontSize || '20px',
|
|
22
|
+
fontWeight: props.fontWeight,
|
|
23
|
+
textShadow: '1px -1px #ffffff, -2px 2px #999, -6px 7px 3px #131f5be6',
|
|
24
|
+
'.text-wave.wave-animetion span': {
|
|
25
|
+
display: 'inline-block',
|
|
26
|
+
padding: '0 4px',
|
|
27
|
+
animation: 'wave-text 1s ease-in-out infinite',
|
|
28
|
+
},
|
|
29
|
+
'.text-wave.wave-animetion': {
|
|
30
|
+
marginTop: '0.6em',
|
|
31
|
+
...cssMap,
|
|
32
|
+
},
|
|
33
|
+
'@keyframes wave-text': {
|
|
34
|
+
'0%': {
|
|
35
|
+
transform: 'translateY(0em)',
|
|
36
|
+
},
|
|
37
|
+
'60%': {
|
|
38
|
+
transform: 'translateY(-0.6em)',
|
|
39
|
+
},
|
|
40
|
+
'100%': {
|
|
41
|
+
transform: 'translateY(0em)',
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
};
|
|
45
|
+
bindGlobalStyle('text-wave-top', css);
|
|
46
|
+
return (
|
|
47
|
+
<div class='text-wave-top'>
|
|
48
|
+
<div class='text-wave wave-animetion'>
|
|
49
|
+
{props.text.split('').map((char, index) => (
|
|
50
|
+
<span class={`span${index}`}>{char}</span>
|
|
51
|
+
))}
|
|
52
|
+
</div>
|
|
53
|
+
</div>
|
|
54
|
+
);
|
|
55
|
+
};
|
|
@@ -1,28 +1,28 @@
|
|
|
1
|
-
import { CssProps, getCurrentTheme, updateTheme } from 'lupine.web';
|
|
2
|
-
import { PopupMenu } from './popup-menu';
|
|
3
|
-
|
|
4
|
-
export type ThemeSelectorProps = {
|
|
5
|
-
className?: string;
|
|
6
|
-
};
|
|
7
|
-
|
|
8
|
-
export const ThemeSelector = ({ className }: ThemeSelectorProps) => {
|
|
9
|
-
const css: CssProps = {
|
|
10
|
-
display: 'flex',
|
|
11
|
-
flexDirection: 'column',
|
|
12
|
-
alignSelf: 'end',
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
const handleSelected = (themeName: string) => {
|
|
16
|
-
updateTheme(themeName);
|
|
17
|
-
};
|
|
18
|
-
const currentTheme = getCurrentTheme();
|
|
19
|
-
const list = [];
|
|
20
|
-
for (let themeName in currentTheme.themes) {
|
|
21
|
-
list.push(themeName);
|
|
22
|
-
}
|
|
23
|
-
return (
|
|
24
|
-
<div css={css} class={['theme-switch', className].join(' ')} title='Select theme'>
|
|
25
|
-
<PopupMenu list={list} defaultValue={currentTheme.themeName} handleSelected={handleSelected}></PopupMenu>
|
|
26
|
-
</div>
|
|
27
|
-
);
|
|
28
|
-
};
|
|
1
|
+
import { CssProps, getCurrentTheme, updateTheme } from 'lupine.web';
|
|
2
|
+
import { PopupMenu } from './popup-menu';
|
|
3
|
+
|
|
4
|
+
export type ThemeSelectorProps = {
|
|
5
|
+
className?: string;
|
|
6
|
+
};
|
|
7
|
+
|
|
8
|
+
export const ThemeSelector = ({ className }: ThemeSelectorProps) => {
|
|
9
|
+
const css: CssProps = {
|
|
10
|
+
display: 'flex',
|
|
11
|
+
flexDirection: 'column',
|
|
12
|
+
alignSelf: 'end',
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
const handleSelected = (themeName: string) => {
|
|
16
|
+
updateTheme(themeName);
|
|
17
|
+
};
|
|
18
|
+
const currentTheme = getCurrentTheme();
|
|
19
|
+
const list = [];
|
|
20
|
+
for (let themeName in currentTheme.themes) {
|
|
21
|
+
list.push(themeName);
|
|
22
|
+
}
|
|
23
|
+
return (
|
|
24
|
+
<div css={css} class={['theme-switch', className].join(' ')} title='Select theme'>
|
|
25
|
+
<PopupMenu list={list} defaultValue={currentTheme.themeName} handleSelected={handleSelected}></PopupMenu>
|
|
26
|
+
</div>
|
|
27
|
+
);
|
|
28
|
+
};
|