@iota/apps-ui-kit 0.9.1 → 0.9.3
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/CHANGELOG.md +24 -0
- package/README.md +34 -4
- package/dist/index.d.ts +4 -17
- package/dist/index.es.js +1090 -1107
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +10 -10
- package/dist/index.umd.js.map +1 -1
- package/dist/style.css +1 -1
- package/package.json +3 -3
- package/src/lib/components/atoms/button-segment/ButtonSegment.tsx +1 -1
- package/src/lib/components/atoms/toggle/toggle.classes.ts +3 -3
- package/src/lib/components/molecules/account/Account.tsx +4 -44
- package/src/lib/components/molecules/address/Address.tsx +1 -2
- package/src/lib/components/organisms/dialog/Dialog.tsx +1 -1
- package/src/lib/components/organisms/table/Table.tsx +3 -0
- package/src/storybook/stories/molecules/Account.stories.tsx +2 -14
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,29 @@
|
|
|
1
1
|
# @iota/apps-ui-kit
|
|
2
2
|
|
|
3
|
+
## 0.9.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 67cba64: improve Address component to allow onOpen prop
|
|
8
|
+
- 54c7803: Update @types/node to v24.
|
|
9
|
+
- 0528d86: add data testId to Account component
|
|
10
|
+
- 10ee721: Increase Dialog height
|
|
11
|
+
- fc9eba3: Add "isDisabled" to TableRowCheckbox
|
|
12
|
+
- 205e35d: improve button segment for mobile devices
|
|
13
|
+
- 10ee721: remove lock action from account component
|
|
14
|
+
- 5613ae1: Correct Toggle's right spacing when enabled
|
|
15
|
+
- b294bf5: add proper readme
|
|
16
|
+
- Updated dependencies [bb33d49]
|
|
17
|
+
- @iota/apps-ui-icons@0.7.3
|
|
18
|
+
|
|
19
|
+
## 0.9.2
|
|
20
|
+
|
|
21
|
+
### Patch Changes
|
|
22
|
+
|
|
23
|
+
- 1925bea: Bump with no changes to fix NPM versions
|
|
24
|
+
- Updated dependencies [1925bea]
|
|
25
|
+
- @iota/apps-ui-icons@0.7.2
|
|
26
|
+
|
|
3
27
|
## 0.9.1
|
|
4
28
|
|
|
5
29
|
### Patch Changes
|
package/README.md
CHANGED
|
@@ -1,15 +1,45 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @iota/apps-ui-kit
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
A UI kit library for building consistent IOTA applications.
|
|
4
4
|
|
|
5
|
-
Installation
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
Install the package using your preferred package manager:
|
|
6
8
|
|
|
7
9
|
```bash
|
|
8
10
|
# Replace with npm, yarn, bun, etc.
|
|
9
11
|
pnpm install @iota/apps-ui-kit
|
|
10
12
|
```
|
|
11
13
|
|
|
12
|
-
|
|
14
|
+
## Configuration
|
|
15
|
+
|
|
16
|
+
1. Import the UI Kit global styles in your app global CSS file (e.g., `src/index.css` or `src/global.css`):
|
|
17
|
+
|
|
18
|
+
```css
|
|
19
|
+
@import '@iota/apps-ui-kit/styles';
|
|
20
|
+
|
|
21
|
+
@tailwind base;
|
|
22
|
+
@tailwind components;
|
|
23
|
+
@tailwind utilities;
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
2. Configure your Tailwind CSS setup to include the UI Kit styles. Update your `tailwind.config.ts` file:
|
|
27
|
+
|
|
28
|
+
```js
|
|
29
|
+
import { uiKitResponsivePreset } from '@iota/apps-ui-kit';
|
|
30
|
+
import type { Config } from 'tailwindcss';
|
|
31
|
+
|
|
32
|
+
export default {
|
|
33
|
+
presets: [uiKitResponsivePreset],
|
|
34
|
+
content: ['./src/**/*.{js,ts,jsx,tsx,mdx}'],
|
|
35
|
+
darkMode: 'class', // configure as needed ('selector' or 'class')
|
|
36
|
+
theme: {
|
|
37
|
+
extend: {},
|
|
38
|
+
},
|
|
39
|
+
} satisfies Partial<Config>;
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
3. Use components from the UI kit in your application:
|
|
13
43
|
|
|
14
44
|
```typescript
|
|
15
45
|
import { Button } from '@iota/apps-ui-kit';
|
package/dist/index.d.ts
CHANGED
|
@@ -59,7 +59,7 @@ export declare interface AccordionHeaderProps {
|
|
|
59
59
|
hideBorder?: boolean;
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
-
export declare function Account({ title, subtitle, badgeType, badgeText,
|
|
62
|
+
export declare function Account({ title, subtitle, badgeType, badgeText, avatarContent, onOptionsClick, onCopy, copyText, onOpen, isCopyable, isExternal, isSelected, isActive, showSelected, badgeTooltipText, badgeTooltipPosition, }: AccountProps): React.JSX.Element;
|
|
63
63
|
|
|
64
64
|
declare interface AccountProps {
|
|
65
65
|
/**
|
|
@@ -70,28 +70,14 @@ declare interface AccountProps {
|
|
|
70
70
|
* The subtitle of the account.
|
|
71
71
|
*/
|
|
72
72
|
subtitle: string;
|
|
73
|
-
/**
|
|
74
|
-
* Whether the account is unlocked.
|
|
75
|
-
*/
|
|
76
|
-
isLocked?: boolean;
|
|
77
73
|
/**
|
|
78
74
|
* Handler for more options click.
|
|
79
75
|
*/
|
|
80
76
|
onOptionsClick?: (e: React.MouseEvent<HTMLButtonElement>) => void;
|
|
81
|
-
/**
|
|
82
|
-
* Handler for the lock account icon click.
|
|
83
|
-
*/
|
|
84
|
-
onLockAccountClick?: (e: React.MouseEvent<HTMLButtonElement>) => void;
|
|
85
|
-
/**
|
|
86
|
-
* Handle for the unlock account icon click.
|
|
87
|
-
*/
|
|
88
|
-
onUnlockAccountClick?: (e: React.MouseEvent<HTMLButtonElement>) => void;
|
|
89
77
|
/**
|
|
90
78
|
* Function to render avatar content.
|
|
91
79
|
*/
|
|
92
|
-
avatarContent: (
|
|
93
|
-
isLocked?: boolean;
|
|
94
|
-
}) => React.JSX.Element;
|
|
80
|
+
avatarContent: () => React.JSX.Element;
|
|
95
81
|
/**
|
|
96
82
|
* The onCopy event of the Address (optional).
|
|
97
83
|
*/
|
|
@@ -1713,11 +1699,12 @@ export declare function TableRow({ children, leading, }: PropsWithChildren<{
|
|
|
1713
1699
|
leading?: React.ReactNode;
|
|
1714
1700
|
}>): JSX.Element;
|
|
1715
1701
|
|
|
1716
|
-
export declare function TableRowCheckbox({ rowIndex, onCheckboxChange, }: TableRowCheckboxProps): React.JSX.Element;
|
|
1702
|
+
export declare function TableRowCheckbox({ rowIndex, onCheckboxChange, isDisabled, }: TableRowCheckboxProps): React.JSX.Element;
|
|
1717
1703
|
|
|
1718
1704
|
export declare interface TableRowCheckboxProps {
|
|
1719
1705
|
rowIndex: number;
|
|
1720
1706
|
onCheckboxChange: (checked: boolean) => void;
|
|
1707
|
+
isDisabled?: boolean;
|
|
1721
1708
|
}
|
|
1722
1709
|
|
|
1723
1710
|
export declare const TextArea: ForwardRefExoticComponent<TextFieldBaseProps & RefAttributes<HTMLTextAreaElement>>;
|