@emporix/cockpit-component-library 0.0.2 → 0.0.4
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/components/buttons/PrimaryButton.d.ts +11 -3
- package/dist/components/buttons/PrimaryButton.d.ts.map +1 -1
- package/dist/components/buttons/SecondaryButton.d.ts +11 -3
- package/dist/components/buttons/SecondaryButton.d.ts.map +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.es.js +553 -535
- package/dist/index.umd.js +4 -4
- package/dist/style.css +1 -1
- package/dist/styles.d.ts +1 -1
- package/package.json +3 -3
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
export interface PrimaryButtonProps {
|
|
3
3
|
/**
|
|
4
|
-
*
|
|
4
|
+
* Text label displayed inside the button
|
|
5
5
|
*/
|
|
6
|
-
|
|
6
|
+
label?: string;
|
|
7
7
|
/**
|
|
8
8
|
* Whether the button is disabled
|
|
9
9
|
*/
|
|
@@ -12,6 +12,14 @@ export interface PrimaryButtonProps {
|
|
|
12
12
|
* Whether the button is loading
|
|
13
13
|
*/
|
|
14
14
|
loading?: boolean;
|
|
15
|
+
/**
|
|
16
|
+
* Optional icon
|
|
17
|
+
*/
|
|
18
|
+
icon?: React.ReactNode;
|
|
19
|
+
/**
|
|
20
|
+
* Icon position relative to the label
|
|
21
|
+
*/
|
|
22
|
+
iconPos?: 'left' | 'right';
|
|
15
23
|
/**
|
|
16
24
|
* Click handler
|
|
17
25
|
*/
|
|
@@ -25,5 +33,5 @@ export interface PrimaryButtonProps {
|
|
|
25
33
|
*/
|
|
26
34
|
'data-testid'?: string;
|
|
27
35
|
}
|
|
28
|
-
export declare const PrimaryButton: ({
|
|
36
|
+
export declare const PrimaryButton: ({ label, disabled, loading, icon, iconPos, onClick, className, "data-testid": testId, ...props }: PrimaryButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
29
37
|
//# sourceMappingURL=PrimaryButton.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrimaryButton.d.ts","sourceRoot":"","sources":["../../../src/components/buttons/PrimaryButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAIzB,MAAM,WAAW,kBAAkB;IACjC;;OAEG;IACH,
|
|
1
|
+
{"version":3,"file":"PrimaryButton.d.ts","sourceRoot":"","sources":["../../../src/components/buttons/PrimaryButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAIzB,MAAM,WAAW,kBAAkB;IACjC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB;;OAEG;IACH,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IACtB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,GAAG,OAAO,CAAA;IAC1B;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAA;CACvB;AAED,eAAO,MAAM,aAAa,GAAI,kGAU3B,kBAAkB,4CAuCpB,CAAA"}
|
|
@@ -1,13 +1,21 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
export interface SecondaryButtonProps {
|
|
3
3
|
/**
|
|
4
|
-
*
|
|
4
|
+
* Text label displayed inside the button
|
|
5
5
|
*/
|
|
6
|
-
|
|
6
|
+
label?: string;
|
|
7
7
|
/**
|
|
8
8
|
* Whether the button is disabled
|
|
9
9
|
*/
|
|
10
10
|
disabled?: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* Optional icon
|
|
13
|
+
*/
|
|
14
|
+
icon?: React.ReactNode;
|
|
15
|
+
/**
|
|
16
|
+
* Icon position relative to the label
|
|
17
|
+
*/
|
|
18
|
+
iconPos?: 'left' | 'right';
|
|
11
19
|
/**
|
|
12
20
|
* Click handler
|
|
13
21
|
*/
|
|
@@ -21,5 +29,5 @@ export interface SecondaryButtonProps {
|
|
|
21
29
|
*/
|
|
22
30
|
'data-testid'?: string;
|
|
23
31
|
}
|
|
24
|
-
export declare const SecondaryButton: ({
|
|
32
|
+
export declare const SecondaryButton: ({ label, disabled, icon, iconPos, onClick, className, "data-testid": testId, ...props }: SecondaryButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
25
33
|
//# sourceMappingURL=SecondaryButton.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SecondaryButton.d.ts","sourceRoot":"","sources":["../../../src/components/buttons/SecondaryButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,MAAM,WAAW,oBAAoB;IACnC;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAA;
|
|
1
|
+
{"version":3,"file":"SecondaryButton.d.ts","sourceRoot":"","sources":["../../../src/components/buttons/SecondaryButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAGzB,MAAM,WAAW,oBAAoB;IACnC;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;OAEG;IACH,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IACtB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,GAAG,OAAO,CAAA;IAC1B;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAA;CACvB;AAED,eAAO,MAAM,eAAe,GAAI,yFAS7B,oBAAoB,4CAmCtB,CAAA"}
|
package/dist/index.d.ts
CHANGED
|
@@ -4,9 +4,9 @@
|
|
|
4
4
|
* For components to render with correct layout and styles in your app,
|
|
5
5
|
* import the library styles once (e.g. in your root entry or App):
|
|
6
6
|
*
|
|
7
|
-
* import '@emporix/component-library/styles'
|
|
7
|
+
* import '@emporix/cockpit-component-library/styles'
|
|
8
8
|
*
|
|
9
|
-
* Or in CSS: @import '@emporix/component-library/styles';
|
|
9
|
+
* Or in CSS: @import '@emporix/cockpit-component-library/styles';
|
|
10
10
|
*/
|
|
11
11
|
export { PrimaryButton } from './components/buttons/PrimaryButton';
|
|
12
12
|
export type { PrimaryButtonProps } from './components/buttons/PrimaryButton';
|