@dxos/react-ui-pickers 0.8.4-main.b97322e → 0.8.4-main.dedc0f3
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/lib/browser/index.mjs +1 -1
- package/dist/lib/browser/index.mjs.map +3 -3
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/node-esm/index.mjs +1 -1
- package/dist/lib/node-esm/index.mjs.map +3 -3
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/types/src/components/EmojiPicker/EmojiPicker.d.ts.map +1 -1
- package/dist/types/src/components/EmojiPicker/EmojiPicker.stories.d.ts +11 -3
- package/dist/types/src/components/EmojiPicker/EmojiPicker.stories.d.ts.map +1 -1
- package/dist/types/src/components/HuePicker/HuePicker.stories.d.ts +13 -3
- package/dist/types/src/components/HuePicker/HuePicker.stories.d.ts.map +1 -1
- package/dist/types/src/components/IconPicker/IconPicker.stories.d.ts +13 -3
- package/dist/types/src/components/IconPicker/IconPicker.stories.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +11 -10
- package/src/components/EmojiPicker/EmojiPicker.stories.tsx +13 -11
- package/src/components/EmojiPicker/EmojiPicker.tsx +2 -2
- package/src/components/HuePicker/HuePicker.stories.tsx +8 -5
- package/src/components/IconPicker/IconPicker.stories.tsx +8 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dxos/react-ui-pickers",
|
|
3
|
-
"version": "0.8.4-main.
|
|
3
|
+
"version": "0.8.4-main.dedc0f3",
|
|
4
4
|
"description": "A collection of picker components.",
|
|
5
5
|
"homepage": "https://dxos.org",
|
|
6
6
|
"bugs": "https://github.com/dxos/dxos/issues",
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
"type": "module",
|
|
10
10
|
"exports": {
|
|
11
11
|
".": {
|
|
12
|
+
"source": "./src/index.ts",
|
|
12
13
|
"types": "./dist/types/src/index.d.ts",
|
|
13
14
|
"browser": "./dist/lib/browser/index.mjs",
|
|
14
15
|
"node": "./dist/lib/node-esm/index.mjs"
|
|
@@ -28,25 +29,25 @@
|
|
|
28
29
|
"@preact-signals/safe-react": "^0.9.0",
|
|
29
30
|
"@radix-ui/react-use-controllable-state": "1.1.0",
|
|
30
31
|
"react-resize-detector": "^11.0.1",
|
|
31
|
-
"@dxos/log": "0.8.4-main.
|
|
32
|
-
"@dxos/react-ui-types": "0.8.4-main.
|
|
33
|
-
"@dxos/util": "0.8.4-main.
|
|
32
|
+
"@dxos/log": "0.8.4-main.dedc0f3",
|
|
33
|
+
"@dxos/react-ui-types": "0.8.4-main.dedc0f3",
|
|
34
|
+
"@dxos/util": "0.8.4-main.dedc0f3"
|
|
34
35
|
},
|
|
35
36
|
"devDependencies": {
|
|
36
37
|
"@types/react": "~18.2.0",
|
|
37
38
|
"@types/react-dom": "~18.2.0",
|
|
38
39
|
"react": "~18.2.0",
|
|
39
40
|
"react-dom": "~18.2.0",
|
|
40
|
-
"vite": "
|
|
41
|
-
"@dxos/react-ui": "0.8.4-main.
|
|
42
|
-
"@dxos/react-ui-theme": "0.8.4-main.
|
|
43
|
-
"@dxos/storybook-utils": "0.8.4-main.
|
|
41
|
+
"vite": "7.1.1",
|
|
42
|
+
"@dxos/react-ui": "0.8.4-main.dedc0f3",
|
|
43
|
+
"@dxos/react-ui-theme": "0.8.4-main.dedc0f3",
|
|
44
|
+
"@dxos/storybook-utils": "0.8.4-main.dedc0f3"
|
|
44
45
|
},
|
|
45
46
|
"peerDependencies": {
|
|
46
47
|
"react": "~18.2.0",
|
|
47
48
|
"react-dom": "~18.2.0",
|
|
48
|
-
"@dxos/react-ui": "0.8.4-main.
|
|
49
|
-
"@dxos/react-ui-theme": "0.8.4-main.
|
|
49
|
+
"@dxos/react-ui": "0.8.4-main.dedc0f3",
|
|
50
|
+
"@dxos/react-ui-theme": "0.8.4-main.dedc0f3"
|
|
50
51
|
},
|
|
51
52
|
"publishConfig": {
|
|
52
53
|
"access": "public"
|
|
@@ -4,13 +4,25 @@
|
|
|
4
4
|
|
|
5
5
|
import '@dxos-theme';
|
|
6
6
|
|
|
7
|
+
import EmojiPicker from '@emoji-mart/react';
|
|
7
8
|
import { type Meta, type StoryObj } from '@storybook/react-vite';
|
|
8
9
|
import React, { useState } from 'react';
|
|
9
10
|
|
|
10
11
|
import { Toolbar } from '@dxos/react-ui';
|
|
11
12
|
import { withLayout, withTheme } from '@dxos/storybook-utils';
|
|
12
13
|
|
|
13
|
-
import { EmojiPickerBlock,
|
|
14
|
+
import { EmojiPickerBlock, type EmojiPickerProps, EmojiPickerToolbarButton } from './EmojiPicker';
|
|
15
|
+
|
|
16
|
+
const meta = {
|
|
17
|
+
title: 'ui/react-ui-pickers/EmojiPicker',
|
|
18
|
+
component: EmojiPicker,
|
|
19
|
+
decorators: [withTheme, withLayout()],
|
|
20
|
+
parameters: {
|
|
21
|
+
layout: 'centered',
|
|
22
|
+
},
|
|
23
|
+
} satisfies Meta<typeof EmojiPicker>;
|
|
24
|
+
|
|
25
|
+
export default meta;
|
|
14
26
|
|
|
15
27
|
const ToolbarButtonStory = (props: EmojiPickerProps) => {
|
|
16
28
|
const [emoji, setEmoji] = useState<string>(props.defaultEmoji ?? '😀');
|
|
@@ -50,13 +62,3 @@ export const Block: StoryObj<EmojiPickerProps> = {
|
|
|
50
62
|
defaultEmoji: '😀',
|
|
51
63
|
},
|
|
52
64
|
};
|
|
53
|
-
|
|
54
|
-
const meta: Meta = {
|
|
55
|
-
title: 'ui/react-ui-pickers/EmojiPicker',
|
|
56
|
-
decorators: [withTheme, withLayout()],
|
|
57
|
-
parameters: {
|
|
58
|
-
layout: 'centered',
|
|
59
|
-
},
|
|
60
|
-
};
|
|
61
|
-
|
|
62
|
-
export default meta;
|
|
@@ -9,7 +9,9 @@ import React, { useState } from 'react';
|
|
|
9
9
|
|
|
10
10
|
import {
|
|
11
11
|
Button,
|
|
12
|
+
ButtonGroup,
|
|
12
13
|
type ButtonProps,
|
|
14
|
+
Icon,
|
|
13
15
|
Popover,
|
|
14
16
|
type ThemedClassName,
|
|
15
17
|
Toolbar,
|
|
@@ -17,8 +19,6 @@ import {
|
|
|
17
19
|
useMediaQuery,
|
|
18
20
|
useThemeContext,
|
|
19
21
|
useTranslation,
|
|
20
|
-
Icon,
|
|
21
|
-
ButtonGroup,
|
|
22
22
|
} from '@dxos/react-ui';
|
|
23
23
|
|
|
24
24
|
import './emoji.css';
|
|
@@ -12,7 +12,7 @@ import { withLayout, withTheme } from '@dxos/storybook-utils';
|
|
|
12
12
|
|
|
13
13
|
import { HuePicker, type HuePickerProps } from './HuePicker';
|
|
14
14
|
|
|
15
|
-
const
|
|
15
|
+
const DefaultStory = (props: HuePickerProps) => {
|
|
16
16
|
const [hue, setHue] = useState<string | undefined>(props.defaultValue);
|
|
17
17
|
|
|
18
18
|
return (
|
|
@@ -28,18 +28,21 @@ const ToolbarStory = (props: HuePickerProps) => {
|
|
|
28
28
|
);
|
|
29
29
|
};
|
|
30
30
|
|
|
31
|
-
const meta
|
|
31
|
+
const meta = {
|
|
32
32
|
title: 'ui/react-ui-pickers/HuePicker',
|
|
33
|
+
component: HuePicker,
|
|
34
|
+
render: DefaultStory,
|
|
33
35
|
decorators: [withTheme, withLayout()],
|
|
34
36
|
parameters: {
|
|
35
37
|
layout: 'centered',
|
|
36
38
|
},
|
|
37
|
-
}
|
|
39
|
+
} satisfies Meta<typeof HuePicker>;
|
|
38
40
|
|
|
39
41
|
export default meta;
|
|
40
42
|
|
|
41
|
-
|
|
42
|
-
|
|
43
|
+
type Story = StoryObj<typeof meta>;
|
|
44
|
+
|
|
45
|
+
export const Default: Story = {
|
|
43
46
|
args: {
|
|
44
47
|
defaultValue: 'red',
|
|
45
48
|
},
|
|
@@ -12,7 +12,7 @@ import { withLayout, withTheme } from '@dxos/storybook-utils';
|
|
|
12
12
|
|
|
13
13
|
import { IconPicker, type IconPickerProps } from './IconPicker';
|
|
14
14
|
|
|
15
|
-
const
|
|
15
|
+
const DefaultStory = (props: IconPickerProps) => {
|
|
16
16
|
const [icon, setIcon] = useState<string | undefined>(props.value ?? props.defaultValue);
|
|
17
17
|
console.log(icon);
|
|
18
18
|
|
|
@@ -23,17 +23,20 @@ const ToolbarStory = (props: IconPickerProps) => {
|
|
|
23
23
|
);
|
|
24
24
|
};
|
|
25
25
|
|
|
26
|
-
const meta
|
|
26
|
+
const meta = {
|
|
27
27
|
title: 'ui/react-ui-pickers/IconPicker',
|
|
28
|
+
component: IconPicker,
|
|
29
|
+
render: DefaultStory,
|
|
28
30
|
decorators: [withTheme, withLayout()],
|
|
29
31
|
parameters: {
|
|
30
32
|
layout: 'centered',
|
|
31
33
|
},
|
|
32
|
-
}
|
|
34
|
+
} satisfies Meta<typeof IconPicker>;
|
|
33
35
|
|
|
34
36
|
export default meta;
|
|
35
37
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
+
type Story = StoryObj<typeof meta>;
|
|
39
|
+
|
|
40
|
+
export const Default: Story = {
|
|
38
41
|
args: {},
|
|
39
42
|
};
|