@speakapbv/dough-component-library 10.0.1 → 10.1.0
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/index.es.js
CHANGED
|
@@ -4518,7 +4518,7 @@ var PanelOverlay = function (props) {
|
|
|
4518
4518
|
};
|
|
4519
4519
|
PanelOverlay.displayName = "PanelOverlay";
|
|
4520
4520
|
|
|
4521
|
-
var css_248z$x = "/* COLORS */\n/* Typography*/\n/*Dennis should provide medium font size*/\n.dough-progress-bar {\n height: 4px;\n width: 100%;\n border-radius: 4px;\n position: relative;\n}\n\n.dough-progress-bar__progress {\n position: absolute;\n height: 100%;\n border-radius: 4px;\n z-index: 1;\n}";
|
|
4521
|
+
var css_248z$x = "/* COLORS */\n/* Typography*/\n/*Dennis should provide medium font size*/\n.dough-progress-bar {\n height: 4px;\n width: 100%;\n border-radius: 4px;\n position: relative;\n}\n\n.dough-progress-bar__progress {\n position: absolute;\n height: 100%;\n border-radius: 4px;\n z-index: 1;\n}\n\n.dough-multi-progress-bar {\n height: 8px;\n width: 100%;\n border-radius: 8px;\n display: flex;\n}\n\n.dough-multi-progress-bar__progress {\n height: 100%;\n z-index: 1;\n border-left: 1px solid rgb(110, 111, 117);\n}\n.dough-multi-progress-bar__progress:first-of-type {\n border-top-left-radius: 4px;\n border-bottom-left-radius: 4px;\n border-left: unset;\n}\n.dough-multi-progress-bar__progress:not(:last-of-type) {\n border-right: 1px solid rgb(110, 111, 117);\n}\n.dough-multi-progress-bar__progress:last-of-type {\n border-top-right-radius: 4px;\n border-bottom-right-radius: 4px;\n}";
|
|
4522
4522
|
styleInject(css_248z$x);
|
|
4523
4523
|
|
|
4524
4524
|
var DesignTokens = {
|
|
@@ -4708,8 +4708,11 @@ var generateStyles = function (props, selector, propToStyleMap, noMediaQuery) {
|
|
|
4708
4708
|
var isStandardColor = function (color) {
|
|
4709
4709
|
return Object.values(Colors).includes(color);
|
|
4710
4710
|
};
|
|
4711
|
+
var isFixedColor = function (color) {
|
|
4712
|
+
return Object.values(FixedColors).includes(color);
|
|
4713
|
+
};
|
|
4711
4714
|
var getColorWithFallback = function (color) {
|
|
4712
|
-
return isStandardColor(color) ? "var(--" + color + ")" : color;
|
|
4715
|
+
return isStandardColor(color) || isFixedColor(color) ? "var(--" + color + ")" : color;
|
|
4713
4716
|
};
|
|
4714
4717
|
|
|
4715
4718
|
var ProgressBar = function (_a) {
|
package/dist/index.js
CHANGED
|
@@ -4501,7 +4501,7 @@ var PanelOverlay = function (props) {
|
|
|
4501
4501
|
};
|
|
4502
4502
|
PanelOverlay.displayName = "PanelOverlay";
|
|
4503
4503
|
|
|
4504
|
-
var css_248z$x = "/* COLORS */\n/* Typography*/\n/*Dennis should provide medium font size*/\n.dough-progress-bar {\n height: 4px;\n width: 100%;\n border-radius: 4px;\n position: relative;\n}\n\n.dough-progress-bar__progress {\n position: absolute;\n height: 100%;\n border-radius: 4px;\n z-index: 1;\n}";
|
|
4504
|
+
var css_248z$x = "/* COLORS */\n/* Typography*/\n/*Dennis should provide medium font size*/\n.dough-progress-bar {\n height: 4px;\n width: 100%;\n border-radius: 4px;\n position: relative;\n}\n\n.dough-progress-bar__progress {\n position: absolute;\n height: 100%;\n border-radius: 4px;\n z-index: 1;\n}\n\n.dough-multi-progress-bar {\n height: 8px;\n width: 100%;\n border-radius: 8px;\n display: flex;\n}\n\n.dough-multi-progress-bar__progress {\n height: 100%;\n z-index: 1;\n border-left: 1px solid rgb(110, 111, 117);\n}\n.dough-multi-progress-bar__progress:first-of-type {\n border-top-left-radius: 4px;\n border-bottom-left-radius: 4px;\n border-left: unset;\n}\n.dough-multi-progress-bar__progress:not(:last-of-type) {\n border-right: 1px solid rgb(110, 111, 117);\n}\n.dough-multi-progress-bar__progress:last-of-type {\n border-top-right-radius: 4px;\n border-bottom-right-radius: 4px;\n}";
|
|
4505
4505
|
styleInject(css_248z$x);
|
|
4506
4506
|
|
|
4507
4507
|
var DesignTokens = {
|
|
@@ -4691,8 +4691,11 @@ var generateStyles = function (props, selector, propToStyleMap, noMediaQuery) {
|
|
|
4691
4691
|
var isStandardColor = function (color) {
|
|
4692
4692
|
return Object.values(exports.Colors).includes(color);
|
|
4693
4693
|
};
|
|
4694
|
+
var isFixedColor = function (color) {
|
|
4695
|
+
return Object.values(exports.FixedColors).includes(color);
|
|
4696
|
+
};
|
|
4694
4697
|
var getColorWithFallback = function (color) {
|
|
4695
|
-
return isStandardColor(color) ? "var(--" + color + ")" : color;
|
|
4698
|
+
return isStandardColor(color) || isFixedColor(color) ? "var(--" + color + ")" : color;
|
|
4696
4699
|
};
|
|
4697
4700
|
|
|
4698
4701
|
var ProgressBar = function (_a) {
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import "./progress-bar.scss";
|
|
2
|
+
import { Colors, DoughDataAttributes, FixedColors } from "../../utils/constants";
|
|
3
|
+
export interface Bar {
|
|
4
|
+
color: Colors | FixedColors | string;
|
|
5
|
+
value: number;
|
|
6
|
+
}
|
|
7
|
+
export interface MultiProgressBarProps {
|
|
8
|
+
className?: string;
|
|
9
|
+
dataAttributes?: DoughDataAttributes;
|
|
10
|
+
total: number;
|
|
11
|
+
railColor?: Colors | string;
|
|
12
|
+
data: Array<Bar>;
|
|
13
|
+
}
|
|
14
|
+
export declare const MultiProgressBar: {
|
|
15
|
+
({ dataAttributes, className, railColor, data, total, }: MultiProgressBarProps): JSX.Element;
|
|
16
|
+
displayName: string;
|
|
17
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
declare const _default: import("@storybook/csf").ComponentAnnotations<import("@storybook/react").ReactFramework, import("./multi-progress-bar").MultiProgressBarProps>;
|
|
2
|
+
export default _default;
|
|
3
|
+
export declare const Empty: import("@storybook/csf").AnnotatedStoryFn<import("@storybook/react").ReactFramework, import("./multi-progress-bar").MultiProgressBarProps>;
|
|
4
|
+
export declare const SingleData: import("@storybook/csf").AnnotatedStoryFn<import("@storybook/react").ReactFramework, import("./multi-progress-bar").MultiProgressBarProps>;
|
|
5
|
+
export declare const MultipleData: import("@storybook/csf").AnnotatedStoryFn<import("@storybook/react").ReactFramework, import("./multi-progress-bar").MultiProgressBarProps>;
|
|
6
|
+
export declare const FullyFilled: import("@storybook/csf").AnnotatedStoryFn<import("@storybook/react").ReactFramework, import("./multi-progress-bar").MultiProgressBarProps>;
|
package/dist/utils/styles.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { Colors } from "./constants";
|
|
1
|
+
import { Colors, FixedColors } from "./constants";
|
|
2
2
|
export declare const getIESpecificStyles: (props: Record<string, any>, propToStyleMap: Record<string, Array<string>>) => string;
|
|
3
3
|
export declare const generateStyles: (props: Record<string, any>, selector: string, propToStyleMap: Record<string, Array<string>>, noMediaQuery?: boolean | undefined) => string;
|
|
4
4
|
export declare const isStandardColor: (color: Colors | string) => color is Colors;
|
|
5
|
-
export declare const
|
|
5
|
+
export declare const isFixedColor: (color: FixedColors | string) => color is FixedColors;
|
|
6
|
+
export declare const getColorWithFallback: (color: Colors | FixedColors | string) => string;
|