@shell-shock/plugin-theme 0.0.6
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/LICENSE +201 -0
- package/README.md +264 -0
- package/dist/_virtual/rolldown_runtime.cjs +29 -0
- package/dist/index.cjs +57 -0
- package/dist/index.d.cts +12 -0
- package/dist/index.d.mts +12 -0
- package/dist/index.mjs +52 -0
- package/dist/style-dictionary/helpers.cjs +148 -0
- package/dist/style-dictionary/helpers.mjs +147 -0
- package/dist/style-dictionary/preprocessor.cjs +1099 -0
- package/dist/style-dictionary/preprocessor.mjs +1098 -0
- package/dist/themes/storm.cjs +81 -0
- package/dist/themes/storm.mjs +80 -0
- package/dist/types/index.cjs +0 -0
- package/dist/types/index.d.cts +3 -0
- package/dist/types/index.d.mts +3 -0
- package/dist/types/index.mjs +1 -0
- package/dist/types/plugin.cjs +0 -0
- package/dist/types/plugin.d.cts +25 -0
- package/dist/types/plugin.d.mts +25 -0
- package/dist/types/plugin.mjs +1 -0
- package/dist/types/theme.cjs +0 -0
- package/dist/types/theme.d.cts +238 -0
- package/dist/types/theme.d.mts +238 -0
- package/dist/types/theme.mjs +1 -0
- package/package.json +127 -0
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
|
|
2
|
+
//#region src/themes/storm.ts
|
|
3
|
+
const theme = {
|
|
4
|
+
$theme: "storm",
|
|
5
|
+
colors: {
|
|
6
|
+
text: {
|
|
7
|
+
banner: {
|
|
8
|
+
title: "#3be4be",
|
|
9
|
+
command: "#ffffff",
|
|
10
|
+
description: "#9ca3af"
|
|
11
|
+
},
|
|
12
|
+
heading: {
|
|
13
|
+
primary: "#ffffff",
|
|
14
|
+
secondary: "#cbd5e1",
|
|
15
|
+
tertiary: "#9ca3af"
|
|
16
|
+
},
|
|
17
|
+
body: {
|
|
18
|
+
primary: "#cbd5e1",
|
|
19
|
+
secondary: "#9ca3af",
|
|
20
|
+
tertiary: "#868b95",
|
|
21
|
+
link: "#3fa6ff"
|
|
22
|
+
},
|
|
23
|
+
message: { description: "#ffffff" },
|
|
24
|
+
usage: {
|
|
25
|
+
bin: "#ffffff",
|
|
26
|
+
command: "#3be4be",
|
|
27
|
+
subcommand: "#22c55e",
|
|
28
|
+
options: "#fca5a5",
|
|
29
|
+
params: "#3fa6ff",
|
|
30
|
+
description: "#9ca3af"
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
border: {
|
|
34
|
+
app: {
|
|
35
|
+
primary: "#ffffff",
|
|
36
|
+
secondary: "#cbd5e1",
|
|
37
|
+
tertiary: "#9ca3af"
|
|
38
|
+
},
|
|
39
|
+
banner: "#3be4be",
|
|
40
|
+
message: {
|
|
41
|
+
help: "#818cf8",
|
|
42
|
+
success: "#45b27e",
|
|
43
|
+
info: "#38bdf8",
|
|
44
|
+
warning: "#f3d371",
|
|
45
|
+
danger: "#d8314a"
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
borderStyles: {
|
|
50
|
+
app: "single",
|
|
51
|
+
banner: "bold",
|
|
52
|
+
message: "round"
|
|
53
|
+
},
|
|
54
|
+
padding: {
|
|
55
|
+
app: 4,
|
|
56
|
+
banner: 14,
|
|
57
|
+
message: 8
|
|
58
|
+
},
|
|
59
|
+
icons: {
|
|
60
|
+
message: { header: {
|
|
61
|
+
help: "✱",
|
|
62
|
+
success: "✔",
|
|
63
|
+
info: "ℹ",
|
|
64
|
+
warning: "⚠",
|
|
65
|
+
danger: "⚠",
|
|
66
|
+
error: "✘"
|
|
67
|
+
} },
|
|
68
|
+
banner: { header: "⏺" }
|
|
69
|
+
},
|
|
70
|
+
labels: { message: { header: {
|
|
71
|
+
help: "Useful Tip",
|
|
72
|
+
success: "Success",
|
|
73
|
+
info: "Info",
|
|
74
|
+
warning: "Warning",
|
|
75
|
+
danger: "Danger",
|
|
76
|
+
error: "Error"
|
|
77
|
+
} } }
|
|
78
|
+
};
|
|
79
|
+
|
|
80
|
+
//#endregion
|
|
81
|
+
exports.theme = theme;
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
//#region src/themes/storm.ts
|
|
2
|
+
const theme = {
|
|
3
|
+
$theme: "storm",
|
|
4
|
+
colors: {
|
|
5
|
+
text: {
|
|
6
|
+
banner: {
|
|
7
|
+
title: "#3be4be",
|
|
8
|
+
command: "#ffffff",
|
|
9
|
+
description: "#9ca3af"
|
|
10
|
+
},
|
|
11
|
+
heading: {
|
|
12
|
+
primary: "#ffffff",
|
|
13
|
+
secondary: "#cbd5e1",
|
|
14
|
+
tertiary: "#9ca3af"
|
|
15
|
+
},
|
|
16
|
+
body: {
|
|
17
|
+
primary: "#cbd5e1",
|
|
18
|
+
secondary: "#9ca3af",
|
|
19
|
+
tertiary: "#868b95",
|
|
20
|
+
link: "#3fa6ff"
|
|
21
|
+
},
|
|
22
|
+
message: { description: "#ffffff" },
|
|
23
|
+
usage: {
|
|
24
|
+
bin: "#ffffff",
|
|
25
|
+
command: "#3be4be",
|
|
26
|
+
subcommand: "#22c55e",
|
|
27
|
+
options: "#fca5a5",
|
|
28
|
+
params: "#3fa6ff",
|
|
29
|
+
description: "#9ca3af"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
border: {
|
|
33
|
+
app: {
|
|
34
|
+
primary: "#ffffff",
|
|
35
|
+
secondary: "#cbd5e1",
|
|
36
|
+
tertiary: "#9ca3af"
|
|
37
|
+
},
|
|
38
|
+
banner: "#3be4be",
|
|
39
|
+
message: {
|
|
40
|
+
help: "#818cf8",
|
|
41
|
+
success: "#45b27e",
|
|
42
|
+
info: "#38bdf8",
|
|
43
|
+
warning: "#f3d371",
|
|
44
|
+
danger: "#d8314a"
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
borderStyles: {
|
|
49
|
+
app: "single",
|
|
50
|
+
banner: "bold",
|
|
51
|
+
message: "round"
|
|
52
|
+
},
|
|
53
|
+
padding: {
|
|
54
|
+
app: 4,
|
|
55
|
+
banner: 14,
|
|
56
|
+
message: 8
|
|
57
|
+
},
|
|
58
|
+
icons: {
|
|
59
|
+
message: { header: {
|
|
60
|
+
help: "✱",
|
|
61
|
+
success: "✔",
|
|
62
|
+
info: "ℹ",
|
|
63
|
+
warning: "⚠",
|
|
64
|
+
danger: "⚠",
|
|
65
|
+
error: "✘"
|
|
66
|
+
} },
|
|
67
|
+
banner: { header: "⏺" }
|
|
68
|
+
},
|
|
69
|
+
labels: { message: { header: {
|
|
70
|
+
help: "Useful Tip",
|
|
71
|
+
success: "Success",
|
|
72
|
+
info: "Info",
|
|
73
|
+
warning: "Warning",
|
|
74
|
+
danger: "Danger",
|
|
75
|
+
error: "Error"
|
|
76
|
+
} } }
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
//#endregion
|
|
80
|
+
export { theme };
|
|
File without changes
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ThemeBorderStyleMessageStateResolvedConfig, ThemeBorderStyleMessageStateUserConfig, ThemeBorderStyleSectionTypesResolvedConfig, ThemeBorderStyleSectionTypesUserConfig, ThemeBorderStyleSubItemResolvedConfig, ThemeBorderStyleSubItemUserConfig, ThemeBorderStylesResolvedConfig, ThemeBorderStylesUserConfig, ThemeColorBannerSubItem, ThemeColorBodySubItem, ThemeColorBorderItemsResolvedConfig, ThemeColorBorderItemsUserConfig, ThemeColorBorderSubItemResolvedConfig, ThemeColorBorderSubItemUserConfig, ThemeColorMessageState, ThemeColorMessageSubItemResolvedConfig, ThemeColorMessageSubItemUserConfig, ThemeColorSubItem, ThemeColorTextItemsResolvedConfig, ThemeColorTextItemsUserConfig, ThemeColorTypesUserConfig, ThemeColorUsageSubItem, ThemeColorsResolvedConfig, ThemeIconMessageStateConfig, ThemeIconSubItemConfig, ThemeIconTypeResolvedConfig, ThemeIconTypeUserConfig, ThemeIconsResolvedConfig, ThemeIconsUserConfig, ThemeLabelMessageStateConfig, ThemeLabelTypeResolvedConfig, ThemeLabelTypeUserConfig, ThemeLabelsResolvedConfig, ThemeLabelsUserConfig, ThemePaddingResolvedConfig, ThemePaddingUserConfig, ThemeResolvedConfig, ThemeStyleBorderIdentifiers, ThemeStyleBorderType, ThemeStyleBorderTypeConfig, ThemeUserConfig } from "./theme.cjs";
|
|
2
|
+
import { ThemePluginContext, ThemePluginOptions, ThemePluginResolvedConfig, ThemePluginUserConfig } from "./plugin.cjs";
|
|
3
|
+
export { ThemeBorderStyleMessageStateResolvedConfig, ThemeBorderStyleMessageStateUserConfig, ThemeBorderStyleSectionTypesResolvedConfig, ThemeBorderStyleSectionTypesUserConfig, ThemeBorderStyleSubItemResolvedConfig, ThemeBorderStyleSubItemUserConfig, ThemeBorderStylesResolvedConfig, ThemeBorderStylesUserConfig, ThemeColorBannerSubItem, ThemeColorBodySubItem, ThemeColorBorderItemsResolvedConfig, ThemeColorBorderItemsUserConfig, ThemeColorBorderSubItemResolvedConfig, ThemeColorBorderSubItemUserConfig, ThemeColorMessageState, ThemeColorMessageSubItemResolvedConfig, ThemeColorMessageSubItemUserConfig, ThemeColorSubItem, ThemeColorTextItemsResolvedConfig, ThemeColorTextItemsUserConfig, ThemeColorTypesUserConfig, ThemeColorUsageSubItem, ThemeColorsResolvedConfig, ThemeIconMessageStateConfig, ThemeIconSubItemConfig, ThemeIconTypeResolvedConfig, ThemeIconTypeUserConfig, ThemeIconsResolvedConfig, ThemeIconsUserConfig, ThemeLabelMessageStateConfig, ThemeLabelTypeResolvedConfig, ThemeLabelTypeUserConfig, ThemeLabelsResolvedConfig, ThemeLabelsUserConfig, ThemePaddingResolvedConfig, ThemePaddingUserConfig, ThemePluginContext, ThemePluginOptions, ThemePluginResolvedConfig, ThemePluginUserConfig, ThemeResolvedConfig, ThemeStyleBorderIdentifiers, ThemeStyleBorderType, ThemeStyleBorderTypeConfig, ThemeUserConfig };
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ThemeBorderStyleMessageStateResolvedConfig, ThemeBorderStyleMessageStateUserConfig, ThemeBorderStyleSectionTypesResolvedConfig, ThemeBorderStyleSectionTypesUserConfig, ThemeBorderStyleSubItemResolvedConfig, ThemeBorderStyleSubItemUserConfig, ThemeBorderStylesResolvedConfig, ThemeBorderStylesUserConfig, ThemeColorBannerSubItem, ThemeColorBodySubItem, ThemeColorBorderItemsResolvedConfig, ThemeColorBorderItemsUserConfig, ThemeColorBorderSubItemResolvedConfig, ThemeColorBorderSubItemUserConfig, ThemeColorMessageState, ThemeColorMessageSubItemResolvedConfig, ThemeColorMessageSubItemUserConfig, ThemeColorSubItem, ThemeColorTextItemsResolvedConfig, ThemeColorTextItemsUserConfig, ThemeColorTypesUserConfig, ThemeColorUsageSubItem, ThemeColorsResolvedConfig, ThemeIconMessageStateConfig, ThemeIconSubItemConfig, ThemeIconTypeResolvedConfig, ThemeIconTypeUserConfig, ThemeIconsResolvedConfig, ThemeIconsUserConfig, ThemeLabelMessageStateConfig, ThemeLabelTypeResolvedConfig, ThemeLabelTypeUserConfig, ThemeLabelsResolvedConfig, ThemeLabelsUserConfig, ThemePaddingResolvedConfig, ThemePaddingUserConfig, ThemeResolvedConfig, ThemeStyleBorderIdentifiers, ThemeStyleBorderType, ThemeStyleBorderTypeConfig, ThemeUserConfig } from "./theme.mjs";
|
|
2
|
+
import { ThemePluginContext, ThemePluginOptions, ThemePluginResolvedConfig, ThemePluginUserConfig } from "./plugin.mjs";
|
|
3
|
+
export { ThemeBorderStyleMessageStateResolvedConfig, ThemeBorderStyleMessageStateUserConfig, ThemeBorderStyleSectionTypesResolvedConfig, ThemeBorderStyleSectionTypesUserConfig, ThemeBorderStyleSubItemResolvedConfig, ThemeBorderStyleSubItemUserConfig, ThemeBorderStylesResolvedConfig, ThemeBorderStylesUserConfig, ThemeColorBannerSubItem, ThemeColorBodySubItem, ThemeColorBorderItemsResolvedConfig, ThemeColorBorderItemsUserConfig, ThemeColorBorderSubItemResolvedConfig, ThemeColorBorderSubItemUserConfig, ThemeColorMessageState, ThemeColorMessageSubItemResolvedConfig, ThemeColorMessageSubItemUserConfig, ThemeColorSubItem, ThemeColorTextItemsResolvedConfig, ThemeColorTextItemsUserConfig, ThemeColorTypesUserConfig, ThemeColorUsageSubItem, ThemeColorsResolvedConfig, ThemeIconMessageStateConfig, ThemeIconSubItemConfig, ThemeIconTypeResolvedConfig, ThemeIconTypeUserConfig, ThemeIconsResolvedConfig, ThemeIconsUserConfig, ThemeLabelMessageStateConfig, ThemeLabelTypeResolvedConfig, ThemeLabelTypeUserConfig, ThemeLabelsResolvedConfig, ThemeLabelsUserConfig, ThemePaddingResolvedConfig, ThemePaddingUserConfig, ThemePluginContext, ThemePluginOptions, ThemePluginResolvedConfig, ThemePluginUserConfig, ThemeResolvedConfig, ThemeStyleBorderIdentifiers, ThemeStyleBorderType, ThemeStyleBorderTypeConfig, ThemeUserConfig };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { };
|
|
File without changes
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ThemeResolvedConfig, ThemeUserConfig } from "./theme.cjs";
|
|
2
|
+
import { StyleDictionaryPluginContext, StyleDictionaryPluginOptions, StyleDictionaryPluginResolvedConfig, StyleDictionaryPluginUserConfig } from "@powerlines/plugin-style-dictionary/types";
|
|
3
|
+
|
|
4
|
+
//#region src/types/plugin.d.ts
|
|
5
|
+
type ThemePluginOptions = StyleDictionaryPluginOptions & {
|
|
6
|
+
/**
|
|
7
|
+
* Theme configuration for the plugin.
|
|
8
|
+
*/
|
|
9
|
+
theme?: ThemeUserConfig;
|
|
10
|
+
};
|
|
11
|
+
type ThemePluginUserConfig = StyleDictionaryPluginUserConfig & ThemePluginOptions;
|
|
12
|
+
type ThemePluginResolvedConfig = StyleDictionaryPluginResolvedConfig & {
|
|
13
|
+
/**
|
|
14
|
+
* Resolved theme configuration for the plugin.
|
|
15
|
+
*/
|
|
16
|
+
theme: ThemeResolvedConfig;
|
|
17
|
+
};
|
|
18
|
+
type ThemePluginContext<TResolvedConfig extends ThemePluginResolvedConfig = ThemePluginResolvedConfig> = StyleDictionaryPluginContext<TResolvedConfig> & {
|
|
19
|
+
/**
|
|
20
|
+
* Resolved theme configuration.
|
|
21
|
+
*/
|
|
22
|
+
theme: ThemeResolvedConfig;
|
|
23
|
+
};
|
|
24
|
+
//#endregion
|
|
25
|
+
export { ThemePluginContext, ThemePluginOptions, ThemePluginResolvedConfig, ThemePluginUserConfig };
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { ThemeResolvedConfig, ThemeUserConfig } from "./theme.mjs";
|
|
2
|
+
import { StyleDictionaryPluginContext, StyleDictionaryPluginOptions, StyleDictionaryPluginResolvedConfig, StyleDictionaryPluginUserConfig } from "@powerlines/plugin-style-dictionary/types";
|
|
3
|
+
|
|
4
|
+
//#region src/types/plugin.d.ts
|
|
5
|
+
type ThemePluginOptions = StyleDictionaryPluginOptions & {
|
|
6
|
+
/**
|
|
7
|
+
* Theme configuration for the plugin.
|
|
8
|
+
*/
|
|
9
|
+
theme?: ThemeUserConfig;
|
|
10
|
+
};
|
|
11
|
+
type ThemePluginUserConfig = StyleDictionaryPluginUserConfig & ThemePluginOptions;
|
|
12
|
+
type ThemePluginResolvedConfig = StyleDictionaryPluginResolvedConfig & {
|
|
13
|
+
/**
|
|
14
|
+
* Resolved theme configuration for the plugin.
|
|
15
|
+
*/
|
|
16
|
+
theme: ThemeResolvedConfig;
|
|
17
|
+
};
|
|
18
|
+
type ThemePluginContext<TResolvedConfig extends ThemePluginResolvedConfig = ThemePluginResolvedConfig> = StyleDictionaryPluginContext<TResolvedConfig> & {
|
|
19
|
+
/**
|
|
20
|
+
* Resolved theme configuration.
|
|
21
|
+
*/
|
|
22
|
+
theme: ThemeResolvedConfig;
|
|
23
|
+
};
|
|
24
|
+
//#endregion
|
|
25
|
+
export { ThemePluginContext, ThemePluginOptions, ThemePluginResolvedConfig, ThemePluginUserConfig };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { };
|
|
File without changes
|
|
@@ -0,0 +1,238 @@
|
|
|
1
|
+
//#region src/types/theme.d.ts
|
|
2
|
+
interface ThemeColorSubItem {
|
|
3
|
+
primary: string;
|
|
4
|
+
secondary: string;
|
|
5
|
+
tertiary: string;
|
|
6
|
+
}
|
|
7
|
+
interface ThemeColorBodySubItem extends ThemeColorSubItem {
|
|
8
|
+
link: string;
|
|
9
|
+
}
|
|
10
|
+
interface ThemeColorBannerSubItem {
|
|
11
|
+
title: string;
|
|
12
|
+
header: string;
|
|
13
|
+
footer: string;
|
|
14
|
+
command: string;
|
|
15
|
+
description: string;
|
|
16
|
+
}
|
|
17
|
+
interface ThemeColorMessageState {
|
|
18
|
+
help: string;
|
|
19
|
+
success: string;
|
|
20
|
+
info: string;
|
|
21
|
+
warning: string;
|
|
22
|
+
danger: string;
|
|
23
|
+
error: string;
|
|
24
|
+
}
|
|
25
|
+
interface ThemeColorMessageSubItemUserConfig {
|
|
26
|
+
link: Partial<ThemeColorMessageState> | string;
|
|
27
|
+
header: Partial<ThemeColorMessageState> | string;
|
|
28
|
+
footer: Partial<ThemeColorMessageState> | string;
|
|
29
|
+
description: Partial<ThemeColorMessageState> | string;
|
|
30
|
+
}
|
|
31
|
+
interface ThemeColorMessageSubItemResolvedConfig {
|
|
32
|
+
link: ThemeColorMessageState;
|
|
33
|
+
header: ThemeColorMessageState;
|
|
34
|
+
footer: ThemeColorMessageState;
|
|
35
|
+
description: ThemeColorMessageState;
|
|
36
|
+
}
|
|
37
|
+
interface ThemeColorUsageSubItem {
|
|
38
|
+
bin: string;
|
|
39
|
+
command: string;
|
|
40
|
+
subcommand: string;
|
|
41
|
+
options: string;
|
|
42
|
+
params: string;
|
|
43
|
+
description: string;
|
|
44
|
+
}
|
|
45
|
+
interface ThemeColorTextItemsUserConfig {
|
|
46
|
+
banner: Partial<ThemeColorBannerSubItem> | string;
|
|
47
|
+
heading: Partial<ThemeColorSubItem> | string;
|
|
48
|
+
body: Partial<ThemeColorBodySubItem> | string;
|
|
49
|
+
message: Partial<ThemeColorMessageSubItemUserConfig> | string;
|
|
50
|
+
usage: Partial<ThemeColorUsageSubItem> | string;
|
|
51
|
+
}
|
|
52
|
+
interface ThemeColorTextItemsResolvedConfig {
|
|
53
|
+
banner: ThemeColorBannerSubItem;
|
|
54
|
+
heading: ThemeColorSubItem;
|
|
55
|
+
body: ThemeColorBodySubItem;
|
|
56
|
+
message: ThemeColorMessageSubItemResolvedConfig;
|
|
57
|
+
usage: ThemeColorUsageSubItem;
|
|
58
|
+
}
|
|
59
|
+
interface ThemeColorBorderSubItemUserConfig<TState extends object> {
|
|
60
|
+
outline: Partial<TState> | string;
|
|
61
|
+
divider: Partial<TState> | string;
|
|
62
|
+
}
|
|
63
|
+
interface ThemeColorBorderSubItemResolvedConfig<TState extends object> {
|
|
64
|
+
outline: TState;
|
|
65
|
+
divider: TState;
|
|
66
|
+
}
|
|
67
|
+
interface ThemeColorBorderItemsUserConfig {
|
|
68
|
+
app: Partial<ThemeColorBorderSubItemUserConfig<ThemeColorSubItem>> | Partial<ThemeColorSubItem> | string;
|
|
69
|
+
banner: Partial<ThemeColorBorderSubItemUserConfig<ThemeColorSubItem>> | Partial<ThemeColorSubItem> | string;
|
|
70
|
+
message: Partial<ThemeColorBorderSubItemUserConfig<ThemeColorMessageState>> | Partial<ThemeColorMessageState> | string;
|
|
71
|
+
}
|
|
72
|
+
interface ThemeColorBorderItemsResolvedConfig {
|
|
73
|
+
app: ThemeColorBorderSubItemResolvedConfig<ThemeColorSubItem>;
|
|
74
|
+
banner: ThemeColorBorderSubItemResolvedConfig<ThemeColorSubItem>;
|
|
75
|
+
message: ThemeColorBorderSubItemResolvedConfig<ThemeColorMessageState>;
|
|
76
|
+
}
|
|
77
|
+
interface ThemeColorTypesUserConfig {
|
|
78
|
+
text: Partial<ThemeColorTextItemsUserConfig> | string;
|
|
79
|
+
border: Partial<ThemeColorBorderItemsUserConfig> | string;
|
|
80
|
+
}
|
|
81
|
+
interface ThemeColorsResolvedConfig {
|
|
82
|
+
text: ThemeColorTextItemsResolvedConfig;
|
|
83
|
+
border: ThemeColorBorderItemsResolvedConfig;
|
|
84
|
+
}
|
|
85
|
+
interface ThemeStyleBorderTypeConfig {
|
|
86
|
+
topLeft: string;
|
|
87
|
+
topRight: string;
|
|
88
|
+
bottomLeft: string;
|
|
89
|
+
bottomRight: string;
|
|
90
|
+
top: string;
|
|
91
|
+
bottom: string;
|
|
92
|
+
left: string;
|
|
93
|
+
right: string;
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* The identifiers of border styles to use in the theme.
|
|
97
|
+
*
|
|
98
|
+
* @remarks
|
|
99
|
+
* The available border styles are:
|
|
100
|
+
* - `"single"`: Single line border (default)
|
|
101
|
+
* - `"double"`: Double line border
|
|
102
|
+
* - `"bold"`: Bold line border
|
|
103
|
+
* - `"round"`: Rounded corner border
|
|
104
|
+
* - `"single-double"`: Single line on top and bottom, double line on sides
|
|
105
|
+
* - `"double-single"`: Double line on top and bottom, single line on sides
|
|
106
|
+
* - `"classic"`: Classic ASCII style border
|
|
107
|
+
* - `"pointer"`: Pointer style border
|
|
108
|
+
* - `"arrow"`: Arrow style border
|
|
109
|
+
* - `"outward-arrow"`: Outward arrow style border
|
|
110
|
+
* - `"inward-arrow"`: Inward arrow style border (alias for `"arrow"`)
|
|
111
|
+
* - `"double-arrow"`: Double arrow style border
|
|
112
|
+
* - `"outward-double-arrow"`: Outward double arrow style border
|
|
113
|
+
* - `"inward-double-arrow"`: Inward double arrow style border (alias for `"double-arrow"`)
|
|
114
|
+
* - `"none"`: No border
|
|
115
|
+
*
|
|
116
|
+
* @see {@link https://www.npmjs.com/package/boxen | Boxen documentation}
|
|
117
|
+
*/
|
|
118
|
+
type ThemeStyleBorderIdentifiers = "single" | "double" | "bold" | "round" | "single-double" | "double-single" | "classic" | "pointer" | "arrow" | "outward-arrow" | "inward-arrow" | "double-arrow" | "outward-double-arrow" | "inward-double-arrow" | "none";
|
|
119
|
+
type ThemeStyleBorderType = ThemeStyleBorderIdentifiers | ThemeStyleBorderTypeConfig;
|
|
120
|
+
interface ThemeBorderStyleMessageStateUserConfig {
|
|
121
|
+
help: ThemeStyleBorderType;
|
|
122
|
+
success: ThemeStyleBorderType;
|
|
123
|
+
info: ThemeStyleBorderType;
|
|
124
|
+
warning: ThemeStyleBorderType;
|
|
125
|
+
danger: ThemeStyleBorderType;
|
|
126
|
+
error: ThemeStyleBorderType;
|
|
127
|
+
}
|
|
128
|
+
interface ThemeBorderStyleMessageStateResolvedConfig {
|
|
129
|
+
help: ThemeStyleBorderTypeConfig;
|
|
130
|
+
success: ThemeStyleBorderTypeConfig;
|
|
131
|
+
info: ThemeStyleBorderTypeConfig;
|
|
132
|
+
warning: ThemeStyleBorderTypeConfig;
|
|
133
|
+
danger: ThemeStyleBorderTypeConfig;
|
|
134
|
+
error: ThemeStyleBorderTypeConfig;
|
|
135
|
+
}
|
|
136
|
+
interface ThemeBorderStyleSubItemUserConfig<TState extends object> {
|
|
137
|
+
outline: Partial<TState> | ThemeStyleBorderType;
|
|
138
|
+
divider: Partial<TState> | ThemeStyleBorderType;
|
|
139
|
+
}
|
|
140
|
+
interface ThemeBorderStyleSubItemResolvedConfig<TState extends object> {
|
|
141
|
+
outline: TState;
|
|
142
|
+
divider: TState;
|
|
143
|
+
}
|
|
144
|
+
interface ThemeBorderStyleSectionTypesUserConfig {
|
|
145
|
+
primary: ThemeStyleBorderType;
|
|
146
|
+
secondary: ThemeStyleBorderType;
|
|
147
|
+
tertiary: ThemeStyleBorderType;
|
|
148
|
+
}
|
|
149
|
+
interface ThemeBorderStyleSectionTypesResolvedConfig {
|
|
150
|
+
primary: ThemeStyleBorderTypeConfig;
|
|
151
|
+
secondary: ThemeStyleBorderTypeConfig;
|
|
152
|
+
tertiary: ThemeStyleBorderTypeConfig;
|
|
153
|
+
}
|
|
154
|
+
interface ThemeBorderStylesUserConfig {
|
|
155
|
+
app: ThemeBorderStyleSubItemUserConfig<ThemeBorderStyleSectionTypesUserConfig> | ThemeStyleBorderType;
|
|
156
|
+
banner: ThemeBorderStyleSubItemUserConfig<ThemeBorderStyleSectionTypesUserConfig> | ThemeStyleBorderType;
|
|
157
|
+
message: ThemeBorderStyleSubItemUserConfig<ThemeBorderStyleMessageStateUserConfig> | ThemeStyleBorderType;
|
|
158
|
+
}
|
|
159
|
+
interface ThemeBorderStylesResolvedConfig {
|
|
160
|
+
banner: ThemeBorderStyleSubItemResolvedConfig<ThemeBorderStyleSectionTypesResolvedConfig>;
|
|
161
|
+
message: ThemeBorderStyleSubItemResolvedConfig<ThemeBorderStyleMessageStateResolvedConfig>;
|
|
162
|
+
app: ThemeBorderStyleSubItemResolvedConfig<ThemeBorderStyleSectionTypesResolvedConfig>;
|
|
163
|
+
}
|
|
164
|
+
interface ThemePaddingUserConfig {
|
|
165
|
+
app: number;
|
|
166
|
+
banner: number;
|
|
167
|
+
message: number;
|
|
168
|
+
}
|
|
169
|
+
interface ThemePaddingResolvedConfig {
|
|
170
|
+
app: number;
|
|
171
|
+
banner: number;
|
|
172
|
+
message: number;
|
|
173
|
+
}
|
|
174
|
+
interface ThemeIconMessageStateConfig {
|
|
175
|
+
help: string;
|
|
176
|
+
success: string;
|
|
177
|
+
info: string;
|
|
178
|
+
warning: string;
|
|
179
|
+
danger: string;
|
|
180
|
+
error: string;
|
|
181
|
+
}
|
|
182
|
+
interface ThemeIconSubItemConfig {
|
|
183
|
+
primary: string;
|
|
184
|
+
secondary: string;
|
|
185
|
+
tertiary: string;
|
|
186
|
+
}
|
|
187
|
+
interface ThemeIconTypeUserConfig<TState extends object> {
|
|
188
|
+
header: Partial<TState> | string;
|
|
189
|
+
}
|
|
190
|
+
interface ThemeIconTypeResolvedConfig<TState extends object> {
|
|
191
|
+
header: TState;
|
|
192
|
+
}
|
|
193
|
+
interface ThemeIconsUserConfig {
|
|
194
|
+
message: ThemeIconTypeUserConfig<ThemeIconMessageStateConfig> | string;
|
|
195
|
+
banner: ThemeIconTypeUserConfig<ThemeIconSubItemConfig> | string;
|
|
196
|
+
}
|
|
197
|
+
interface ThemeIconsResolvedConfig {
|
|
198
|
+
message: ThemeIconTypeResolvedConfig<ThemeIconMessageStateConfig>;
|
|
199
|
+
banner: ThemeIconTypeResolvedConfig<ThemeIconSubItemConfig>;
|
|
200
|
+
}
|
|
201
|
+
interface ThemeLabelMessageStateConfig {
|
|
202
|
+
help: string;
|
|
203
|
+
success: string;
|
|
204
|
+
info: string;
|
|
205
|
+
warning: string;
|
|
206
|
+
danger: string;
|
|
207
|
+
error: string;
|
|
208
|
+
}
|
|
209
|
+
interface ThemeLabelTypeUserConfig {
|
|
210
|
+
header: Partial<ThemeLabelMessageStateConfig> | string;
|
|
211
|
+
}
|
|
212
|
+
interface ThemeLabelTypeResolvedConfig {
|
|
213
|
+
header: ThemeLabelMessageStateConfig;
|
|
214
|
+
}
|
|
215
|
+
interface ThemeLabelsUserConfig {
|
|
216
|
+
message: ThemeLabelTypeUserConfig | string;
|
|
217
|
+
}
|
|
218
|
+
interface ThemeLabelsResolvedConfig {
|
|
219
|
+
message: ThemeLabelTypeResolvedConfig;
|
|
220
|
+
}
|
|
221
|
+
interface ThemeUserConfig {
|
|
222
|
+
$theme?: string;
|
|
223
|
+
colors?: Partial<ThemeColorTypesUserConfig> | string;
|
|
224
|
+
borderStyles?: Partial<ThemeBorderStylesUserConfig> | ThemeStyleBorderType;
|
|
225
|
+
padding?: Partial<ThemePaddingUserConfig> | number;
|
|
226
|
+
icons?: Partial<ThemeIconsUserConfig> | string;
|
|
227
|
+
labels?: Partial<ThemeLabelsUserConfig> | string;
|
|
228
|
+
}
|
|
229
|
+
interface ThemeResolvedConfig {
|
|
230
|
+
name: string;
|
|
231
|
+
colors: ThemeColorsResolvedConfig;
|
|
232
|
+
borderStyles: ThemeBorderStylesResolvedConfig;
|
|
233
|
+
padding: ThemePaddingResolvedConfig;
|
|
234
|
+
icons: ThemeIconsResolvedConfig;
|
|
235
|
+
labels: ThemeLabelsResolvedConfig;
|
|
236
|
+
}
|
|
237
|
+
//#endregion
|
|
238
|
+
export { ThemeBorderStyleMessageStateResolvedConfig, ThemeBorderStyleMessageStateUserConfig, ThemeBorderStyleSectionTypesResolvedConfig, ThemeBorderStyleSectionTypesUserConfig, ThemeBorderStyleSubItemResolvedConfig, ThemeBorderStyleSubItemUserConfig, ThemeBorderStylesResolvedConfig, ThemeBorderStylesUserConfig, ThemeColorBannerSubItem, ThemeColorBodySubItem, ThemeColorBorderItemsResolvedConfig, ThemeColorBorderItemsUserConfig, ThemeColorBorderSubItemResolvedConfig, ThemeColorBorderSubItemUserConfig, ThemeColorMessageState, ThemeColorMessageSubItemResolvedConfig, ThemeColorMessageSubItemUserConfig, ThemeColorSubItem, ThemeColorTextItemsResolvedConfig, ThemeColorTextItemsUserConfig, ThemeColorTypesUserConfig, ThemeColorUsageSubItem, ThemeColorsResolvedConfig, ThemeIconMessageStateConfig, ThemeIconSubItemConfig, ThemeIconTypeResolvedConfig, ThemeIconTypeUserConfig, ThemeIconsResolvedConfig, ThemeIconsUserConfig, ThemeLabelMessageStateConfig, ThemeLabelTypeResolvedConfig, ThemeLabelTypeUserConfig, ThemeLabelsResolvedConfig, ThemeLabelsUserConfig, ThemePaddingResolvedConfig, ThemePaddingUserConfig, ThemeResolvedConfig, ThemeStyleBorderIdentifiers, ThemeStyleBorderType, ThemeStyleBorderTypeConfig, ThemeUserConfig };
|