pangea-lib 2.9.16 → 2.10.1
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/dist/main.cjs.js +19 -19
- package/dist/main.css +1 -1
- package/dist/main.es.js +7514 -7545
- package/dist/styles/helpers.styl +15 -15
- package/dist/styles/variables/breakpoints.styl +4 -4
- package/dist/types/colors/colors.helpers.d.ts +3 -3
- package/dist/types/colors/colors.store.d.ts +3 -14
- package/dist/types/colors/colors.types.d.ts +10 -13
- package/dist/types/colors/index.d.ts +2 -5
- package/dist/types/colors/theme.store.d.ts +1 -4
- package/dist/types/components/PgaBadge.vue.d.ts +4 -4
- package/dist/types/components/PgaSpinner.vue.d.ts +4 -4
- package/dist/types/components/button/PgaButton.vue.d.ts +8 -8
- package/dist/types/helpers/css.d.ts +3 -0
- package/dist/types/options/options.store.d.ts +3 -3
- package/dist/types/options/options.types.d.ts +2 -2
- package/dist/types/types/button.d.ts +1 -1
- package/dist/types/types/color.d.ts +5 -0
- package/dist/types/types/index.d.ts +1 -0
- package/package.json +2 -2
- /package/dist/types/options/{options.d.ts → all-options.d.ts} +0 -0
package/dist/styles/helpers.styl
CHANGED
|
@@ -30,15 +30,15 @@ margin-x()
|
|
|
30
30
|
else
|
|
31
31
|
margin-right arguments[1]
|
|
32
32
|
|
|
33
|
-
size($
|
|
34
|
-
height $
|
|
35
|
-
min-height $
|
|
36
|
-
if $
|
|
37
|
-
width $
|
|
38
|
-
min-width $
|
|
33
|
+
size($size-height, $size-width = false)
|
|
34
|
+
height $size-height
|
|
35
|
+
min-height $size-height
|
|
36
|
+
if $size-width
|
|
37
|
+
width $size-width
|
|
38
|
+
min-width $size-width
|
|
39
39
|
else
|
|
40
|
-
width $
|
|
41
|
-
min-width $
|
|
40
|
+
width $size-height
|
|
41
|
+
min-width $size-height
|
|
42
42
|
|
|
43
43
|
size-rounded($size)
|
|
44
44
|
size($size)
|
|
@@ -47,17 +47,17 @@ size-rounded($size)
|
|
|
47
47
|
shadow($blur = 1rem, $color = rgba(0, 0, 0, 0.2))
|
|
48
48
|
box-shadow 0 0 $blur $color
|
|
49
49
|
|
|
50
|
-
flex($
|
|
50
|
+
flex($flex-direction = row, $justify-content = flex-start, $align-items = stretch, $gap = 0, $flex-wrap = nowrap)
|
|
51
51
|
display flex
|
|
52
|
-
flex-direction $
|
|
53
|
-
justify-content $
|
|
54
|
-
align-items $
|
|
52
|
+
flex-direction $flex-direction
|
|
53
|
+
justify-content $justify-content
|
|
54
|
+
align-items $align-items
|
|
55
55
|
gap $gap
|
|
56
|
-
flex-wrap $
|
|
56
|
+
flex-wrap $flex-wrap
|
|
57
57
|
|
|
58
58
|
flex-center()
|
|
59
59
|
flex(row, center, center)
|
|
60
60
|
|
|
61
|
-
dynamic-rgba($
|
|
61
|
+
dynamic-rgba($rgb-values, $opacity = 1)
|
|
62
62
|
// return rgba as a string so it doesn't get interpolated by stylus compiler
|
|
63
|
-
s('rgba(%s, %s)', $
|
|
63
|
+
s('rgba(%s, %s)', $rgb-values, $opacity)
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// Large desktops
|
|
2
2
|
// no breakpoint since this is the default
|
|
3
3
|
// Desktops
|
|
4
|
-
$
|
|
4
|
+
$breakpoint-large-devices = 1200px
|
|
5
5
|
// Tablets
|
|
6
|
-
$
|
|
6
|
+
$breakpoint-medium-devices = 992px
|
|
7
7
|
// Landscape phones
|
|
8
|
-
$
|
|
8
|
+
$breakpoint-small-devices = 768px
|
|
9
9
|
// Portrait phones
|
|
10
|
-
$
|
|
10
|
+
$breakpoint-extra-small-devices = 576px
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ColorHex } from '../types/color';
|
|
2
|
+
import { AppColor, AppColorType } from './colors.types';
|
|
2
3
|
|
|
3
|
-
export declare function rgba(color: Color, colorAlpha: ColorAlpha): ColorRgba;
|
|
4
4
|
export declare function getColorType(color: AppColor): AppColorType;
|
|
5
|
-
export declare function
|
|
5
|
+
export declare function setColorsVariable(colorName: string, color: ColorHex): void;
|
|
@@ -1,15 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppColorName, AppColor, AppColors } from './colors.types';
|
|
2
2
|
|
|
3
|
-
export declare
|
|
4
|
-
|
|
5
|
-
setColor: (colorName: AppColorName, newColor: AppColor) => void;
|
|
6
|
-
setColors: (newColors: AppColors) => void;
|
|
7
|
-
}, never>>, Pick<{
|
|
8
|
-
colors: import('vue').ComputedRef<StoreColors>;
|
|
9
|
-
setColor: (colorName: AppColorName, newColor: AppColor) => void;
|
|
10
|
-
setColors: (newColors: AppColors) => void;
|
|
11
|
-
}, "colors">, Pick<{
|
|
12
|
-
colors: import('vue').ComputedRef<StoreColors>;
|
|
13
|
-
setColor: (colorName: AppColorName, newColor: AppColor) => void;
|
|
14
|
-
setColors: (newColors: AppColors) => void;
|
|
15
|
-
}, "setColor" | "setColors">>;
|
|
3
|
+
export declare function setColor(colorName: AppColorName, newColor: AppColor): void;
|
|
4
|
+
export declare function setColors(newColors: AppColors): void;
|
|
@@ -1,21 +1,18 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export type ColorRgba = `rgba(${number}, ${number}, ${number}, ${number})`;
|
|
4
|
-
export type ColorHex = `#${string}`;
|
|
5
|
-
export type Color = ColorRgb | ColorRgba | ColorHex;
|
|
1
|
+
import { ColorHex } from '../types/color';
|
|
2
|
+
|
|
6
3
|
export type AppColorNameTheme = 'textFirst' | 'textSecond' | 'textThird' | 'backgroundFirst' | 'backgroundSecond' | 'backgroundThird';
|
|
7
4
|
export type AppColorNameProp = 'primary' | 'secondary' | 'success' | 'warning' | 'danger' | 'dark' | 'light' | 'red' | 'purple' | 'sky' | 'beige';
|
|
8
5
|
export type AppColorNameInformative = 'info' | 'link' | 'error';
|
|
9
6
|
export type AppColorName = AppColorNameTheme | AppColorNameProp | AppColorNameInformative;
|
|
10
7
|
export type AppColorTheme = {
|
|
11
|
-
light:
|
|
12
|
-
dark:
|
|
8
|
+
light: ColorHex;
|
|
9
|
+
dark: ColorHex;
|
|
13
10
|
};
|
|
14
11
|
export type AppColorProp = {
|
|
15
|
-
main:
|
|
16
|
-
contrast:
|
|
12
|
+
main: ColorHex;
|
|
13
|
+
contrast: ColorHex;
|
|
17
14
|
};
|
|
18
|
-
export type AppColorInformative =
|
|
15
|
+
export type AppColorInformative = ColorHex;
|
|
19
16
|
export type AppColor = AppColorTheme | AppColorProp | AppColorInformative;
|
|
20
17
|
export type AppColorThemes = {
|
|
21
18
|
[K in AppColorNameTheme]: AppColorTheme;
|
|
@@ -29,12 +26,12 @@ export type AppColorInformatives = {
|
|
|
29
26
|
export type AppColors = AppColorThemes & AppColorProps & AppColorInformatives;
|
|
30
27
|
export type AppColorType = 'theme' | 'prop' | 'informative';
|
|
31
28
|
export type StoreColorThemes = {
|
|
32
|
-
[K in AppColorNameTheme]:
|
|
29
|
+
[K in AppColorNameTheme]: ColorHex;
|
|
33
30
|
};
|
|
34
31
|
export type StoreColorProps = {
|
|
35
|
-
[K in AppColorNameProp as `${K}`]:
|
|
32
|
+
[K in AppColorNameProp as `${K}`]: ColorHex;
|
|
36
33
|
} & {
|
|
37
|
-
[K in AppColorNameProp as `${K}Contrast`]:
|
|
34
|
+
[K in AppColorNameProp as `${K}Contrast`]: ColorHex;
|
|
38
35
|
};
|
|
39
36
|
export type StoreColorInformatives = AppColorInformatives;
|
|
40
37
|
export type StoreColors = StoreColorThemes & StoreColorProps & StoreColorInformatives;
|
|
@@ -1,11 +1,8 @@
|
|
|
1
1
|
export type Theme = 'light' | 'dark';
|
|
2
2
|
export declare const useThemeStore: import('pinia').StoreDefinition<"pga-theme", import('pinia')._UnwrapAll<Pick<{
|
|
3
3
|
theme: import('vue').Ref<Theme>;
|
|
4
|
-
setTheme: (newTheme: Theme) => void;
|
|
5
4
|
}, "theme">>, Pick<{
|
|
6
5
|
theme: import('vue').Ref<Theme>;
|
|
7
|
-
setTheme: (newTheme: Theme) => void;
|
|
8
6
|
}, never>, Pick<{
|
|
9
7
|
theme: import('vue').Ref<Theme>;
|
|
10
|
-
|
|
11
|
-
}, "setTheme">>;
|
|
8
|
+
}, never>>;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AppColorNameProp } from '../colors';
|
|
2
2
|
|
|
3
3
|
declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
4
|
-
color?:
|
|
4
|
+
color?: AppColorNameProp;
|
|
5
5
|
}>, {
|
|
6
6
|
color: string;
|
|
7
7
|
}>, {}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
8
|
-
color?:
|
|
8
|
+
color?: AppColorNameProp;
|
|
9
9
|
}>, {
|
|
10
10
|
color: string;
|
|
11
11
|
}>>>, {
|
|
12
|
-
color:
|
|
12
|
+
color: AppColorNameProp;
|
|
13
13
|
}, {}>, {
|
|
14
14
|
default?(_: {}): any;
|
|
15
15
|
}>;
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { Color, AppColorNameProp } from '../colors';
|
|
2
1
|
import { Size } from '../types';
|
|
2
|
+
import { AppColorNameProp } from '../colors';
|
|
3
3
|
|
|
4
4
|
declare const _default: import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
5
|
-
color?: AppColorNameProp
|
|
5
|
+
color?: AppColorNameProp;
|
|
6
6
|
size?: Size;
|
|
7
7
|
}>, {
|
|
8
8
|
color: string;
|
|
9
9
|
size: string;
|
|
10
10
|
}>, {}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
11
|
-
color?: AppColorNameProp
|
|
11
|
+
color?: AppColorNameProp;
|
|
12
12
|
size?: Size;
|
|
13
13
|
}>, {
|
|
14
14
|
color: string;
|
|
15
15
|
size: string;
|
|
16
16
|
}>>>, {
|
|
17
|
-
color: AppColorNameProp
|
|
17
|
+
color: AppColorNameProp;
|
|
18
18
|
size: Size;
|
|
19
19
|
}, {}>;
|
|
20
20
|
export default _default;
|
|
@@ -1,31 +1,31 @@
|
|
|
1
|
+
import { Icon, TextProp, Size, ButtonType } from '../../types';
|
|
1
2
|
import { AppColorNameProp } from '../../colors';
|
|
2
|
-
import { Icon, TextProp, Size, ButtonStyle } from '../../types';
|
|
3
3
|
|
|
4
4
|
declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
5
5
|
icon?: Icon;
|
|
6
6
|
text?: TextProp;
|
|
7
|
-
type?:
|
|
8
|
-
|
|
7
|
+
type?: ButtonType;
|
|
8
|
+
color?: AppColorNameProp;
|
|
9
9
|
size?: Size;
|
|
10
10
|
isLoading?: boolean;
|
|
11
11
|
numberToDisplay?: number;
|
|
12
12
|
}>, {
|
|
13
|
-
|
|
13
|
+
color: string;
|
|
14
14
|
size: string;
|
|
15
15
|
}>, {}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
16
16
|
icon?: Icon;
|
|
17
17
|
text?: TextProp;
|
|
18
|
-
type?:
|
|
19
|
-
|
|
18
|
+
type?: ButtonType;
|
|
19
|
+
color?: AppColorNameProp;
|
|
20
20
|
size?: Size;
|
|
21
21
|
isLoading?: boolean;
|
|
22
22
|
numberToDisplay?: number;
|
|
23
23
|
}>, {
|
|
24
|
-
|
|
24
|
+
color: string;
|
|
25
25
|
size: string;
|
|
26
26
|
}>>>, {
|
|
27
|
+
color: AppColorNameProp;
|
|
27
28
|
size: Size;
|
|
28
|
-
type: AppColorNameProp;
|
|
29
29
|
}, {}>, {
|
|
30
30
|
default?(_: {}): any;
|
|
31
31
|
}>;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
export declare const useOptionsStore: import('pinia').StoreDefinition<"pga-options", import('pinia')._UnwrapAll<Pick<{
|
|
2
2
|
options: import('vue').Ref<{
|
|
3
3
|
button: {
|
|
4
|
-
|
|
4
|
+
type: import('../types').ButtonType;
|
|
5
5
|
};
|
|
6
6
|
}>;
|
|
7
7
|
}, "options">>, Pick<{
|
|
8
8
|
options: import('vue').Ref<{
|
|
9
9
|
button: {
|
|
10
|
-
|
|
10
|
+
type: import('../types').ButtonType;
|
|
11
11
|
};
|
|
12
12
|
}>;
|
|
13
13
|
}, never>, Pick<{
|
|
14
14
|
options: import('vue').Ref<{
|
|
15
15
|
button: {
|
|
16
|
-
|
|
16
|
+
type: import('../types').ButtonType;
|
|
17
17
|
};
|
|
18
18
|
}>;
|
|
19
19
|
}, never>>;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { Theme } from '../colors/theme.store';
|
|
2
2
|
import { AppColors } from '../colors/colors.types';
|
|
3
|
-
import {
|
|
3
|
+
import { ButtonType } from '../types/button';
|
|
4
4
|
import { DeepPartial } from 'pangea-helpers';
|
|
5
5
|
|
|
6
6
|
export type OptionsStore = {
|
|
7
7
|
button: {
|
|
8
|
-
|
|
8
|
+
type: ButtonType;
|
|
9
9
|
};
|
|
10
10
|
};
|
|
11
11
|
export type Options = OptionsStore & {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type
|
|
1
|
+
export type ButtonType = 'filled' | 'outlined';
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pangea-lib",
|
|
3
3
|
"description": "",
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.10.1",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"files": [
|
|
7
7
|
"dist"
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"chart.js": "^4.4.3",
|
|
53
53
|
"click-outside-vue3": "^4.0.1",
|
|
54
54
|
"moment": "^2.30.1",
|
|
55
|
-
"pangea-helpers": "^1.3.
|
|
55
|
+
"pangea-helpers": "^1.3.7",
|
|
56
56
|
"pinia": "^2.1.7",
|
|
57
57
|
"pinia-plugin-persistedstate": "^3.2.1",
|
|
58
58
|
"sanitize.css": "^13.0.0",
|
|
File without changes
|