@particle-network/ui-native 0.3.0-beta.2 → 0.3.0-beta.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.
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ import type { View } from 'react-native';
3
+ import type { IconProps } from '../../icons/types';
4
+ import { type VStackProps } from '../layout/VStack';
5
+ export interface UXEmptyProps extends VStackProps {
6
+ iconProps?: IconProps;
7
+ text?: React.ReactNode;
8
+ }
9
+ export declare const UXEmpty: React.ForwardRefExoticComponent<UXEmptyProps & React.RefAttributes<View>>;
@@ -0,0 +1,34 @@
1
+ import { jsx, jsxs } from "react/jsx-runtime";
2
+ import { forwardRef } from "react";
3
+ import { useI18n } from "../../hooks/useI18n.js";
4
+ import { useMs } from "../../hooks/useMs.js";
5
+ import { Icon } from "../../icons/index.js";
6
+ import { VStack } from "../layout/VStack.js";
7
+ import { Text } from "../Text/index.js";
8
+ const UXEmpty = /*#__PURE__*/ forwardRef((props, ref)=>{
9
+ const i18n = useI18n();
10
+ const { ms } = useMs();
11
+ const { text = i18n.table.emptyContent, iconProps, ...restProps } = props;
12
+ return /*#__PURE__*/ jsxs(VStack, {
13
+ ref: ref,
14
+ center: true,
15
+ gap: 4,
16
+ ...restProps,
17
+ children: [
18
+ /*#__PURE__*/ jsx(Icon, {
19
+ name: "empty",
20
+ color: "secondary",
21
+ size: ms(64),
22
+ ...iconProps
23
+ }),
24
+ /*#__PURE__*/ jsx(Text, {
25
+ h3: true,
26
+ color: "secondary",
27
+ fontWeight: "normal",
28
+ children: text
29
+ })
30
+ ]
31
+ });
32
+ });
33
+ UXEmpty.displayName = 'UXEmpty';
34
+ export { UXEmpty };
@@ -13,6 +13,7 @@ export * from './UXButton';
13
13
  export * from './UXCheckbox';
14
14
  export * from './UXChip';
15
15
  export * from './UXDivider';
16
+ export * from './UXEmpty';
16
17
  export * from './UXHint';
17
18
  export * from './UXListBox';
18
19
  export * from './UXModal';
@@ -13,6 +13,7 @@ export * from "./UXButton/index.js";
13
13
  export * from "./UXCheckbox/index.js";
14
14
  export * from "./UXChip/index.js";
15
15
  export * from "./UXDivider/index.js";
16
+ export * from "./UXEmpty/index.js";
16
17
  export * from "./UXHint/index.js";
17
18
  export * from "./UXListBox/index.js";
18
19
  export * from "./UXModal/index.js";
@@ -114,6 +114,30 @@ const Icon = ({ name, size = 16, color = 'default', ...props })=>{
114
114
  fill: colorValue
115
115
  })
116
116
  });
117
+ case 'empty':
118
+ return /*#__PURE__*/ jsxs(react_native_svg, {
119
+ width: size,
120
+ height: size,
121
+ viewBox: "0 0 24 24",
122
+ fill: "none",
123
+ ...props,
124
+ children: [
125
+ /*#__PURE__*/ jsx(Path, {
126
+ opacity: 0.1,
127
+ d: "M2.2417 20.723C2.2417 21.4283 6.81537 21.9999 12.4573 21.9999C18.0992 21.9999 22.6729 21.4283 22.6729 20.723C22.6729 20.0177 18.0992 19.446 12.4573 19.446C6.81537 19.446 2.2417 20.0177 2.2417 20.723Z",
128
+ fill: colorValue
129
+ }),
130
+ /*#__PURE__*/ jsx(Path, {
131
+ d: "M2 8.57303C2 8.79011 2.166 8.95612 2.38308 8.95612C2.60017 8.95612 2.76617 8.79011 2.76617 8.57303C2.76617 8.35596 2.60017 8.18995 2.38308 8.18995C2.17877 8.18995 2 8.36872 2 8.57303ZM22.7999 19.1269C22.3147 19.2548 22.2127 19.3568 22.0976 19.8292C21.9697 19.344 21.8677 19.242 21.3951 19.1269C21.8675 18.999 21.9825 18.8971 22.0976 18.4246C22.2125 18.8971 22.3147 19.012 22.7999 19.1269ZM4.13251 7.23225C3.5068 7.39825 3.37911 7.52595 3.2131 8.15165C3.0471 7.52595 2.9194 7.39825 2.2937 7.23225C2.9194 7.06625 3.0471 6.92579 3.2131 6.31286C3.36634 6.93856 3.5068 7.06625 4.13251 7.23225ZM20.653 5.43496C20.27 5.53712 20.1931 5.61373 20.0912 5.99681C19.989 5.61373 19.9124 5.53712 19.5293 5.43496C19.9126 5.33281 19.9892 5.25619 20.0912 4.87311C20.1806 5.25619 20.27 5.33281 20.653 5.43496ZM22.3003 3.46848C21.3043 3.72387 21.1 3.94094 20.832 4.93696C20.5764 3.94094 20.3593 3.73663 19.3635 3.46848C20.3593 3.21309 20.5639 2.99601 20.832 2C21.0872 2.98324 21.3043 3.20032 22.3003 3.46848ZM21.1399 12.9402V12.9144C21.1399 12.8891 21.1273 12.8763 21.1273 12.8508V12.838L18.3815 6.87152C18.19 6.28087 17.8161 5.76615 17.3137 5.40134C16.8112 5.03653 16.2061 4.84041 15.5851 4.84119H9.34087C8.06392 4.84119 6.9402 5.65843 6.54434 6.87152L3.7989 12.838V12.8506C3.78613 12.8761 3.78613 12.8889 3.78613 12.9142V18.0732C3.78613 19.6948 5.10139 20.2119 6.72312 20.2119H18.2155C19.8374 20.2119 21.1526 19.6948 21.1526 18.0732V12.9657C21.1399 12.9531 21.1399 12.9531 21.1399 12.9402ZM7.25944 7.13967C7.25944 7.13967 7.25944 7.1269 7.27221 7.1269C7.55314 6.20751 8.39592 5.60735 9.34087 5.60735H15.5724C16.5171 5.60735 17.3601 6.20751 17.6538 7.11413C17.6538 7.11413 17.6538 7.1269 17.6664 7.1269L20.2075 12.57H14.372C14.155 12.57 13.989 12.736 13.989 12.9531C13.989 13.7957 13.2996 14.4855 12.4566 14.4855C11.6138 14.4855 10.9243 13.7957 10.9243 12.9531C10.9243 12.736 10.7583 12.57 10.5412 12.57H4.71831L7.25944 7.13967ZM20.3737 18.0736C20.3737 19.274 19.4034 19.4462 18.2029 19.4462H6.71035C5.51002 19.4462 4.53953 19.274 4.53953 18.0736V13.3488H10.1964C10.3752 14.4342 11.3201 15.2644 12.4566 15.2644C13.5929 15.2644 14.5381 14.4344 14.7168 13.3488H20.3737V18.0736Z",
132
+ fill: colorValue
133
+ }),
134
+ /*#__PURE__*/ jsx(Path, {
135
+ opacity: 0.2,
136
+ d: "M12.4562 13.6042C12.3721 13.605 12.2887 13.5891 12.2109 13.5573C12.133 13.5255 12.0623 13.4785 12.0029 13.419C11.9434 13.3596 11.8964 13.2889 11.8646 13.211C11.8328 13.1332 11.8169 13.0498 11.8177 12.9657V11.6888H6.00757L8.10177 7.42061L8.11454 7.39508C8.29331 6.85876 8.77855 6.50122 9.34041 6.50122H15.5719C16.1336 6.50122 16.6188 6.85876 16.7978 7.39508L16.8106 7.42061L18.9048 11.6888H13.0946V12.9657C13.0946 13.3233 12.8137 13.6042 12.4562 13.6042Z",
137
+ fill: colorValue
138
+ })
139
+ ]
140
+ });
117
141
  default:
118
142
  return null;
119
143
  }
@@ -1,7 +1,7 @@
1
1
  import type { SvgProps } from 'react-native-svg';
2
2
  import type { UXForegroundColor } from '@particle-network/ui-shared';
3
3
  export type IconProps = SvgProps & {
4
- name: 'check' | 'close' | 'dot' | 'radioOff' | 'radioOn' | 'question' | 'arrow-right';
4
+ name: 'check' | 'close' | 'dot' | 'radioOff' | 'radioOn' | 'question' | 'arrow-right' | 'empty';
5
5
  size?: number;
6
6
  color?: UXForegroundColor;
7
7
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@particle-network/ui-native",
3
- "version": "0.3.0-beta.2",
3
+ "version": "0.3.0-beta.3",
4
4
  "main": "./entry.js",
5
5
  "react-native": "./dist/index.js",
6
6
  "module": "./dist/index.js",
@@ -91,7 +91,7 @@
91
91
  "vite": "^6.3.5",
92
92
  "zustand": "^5.0.8",
93
93
  "@particle-network/eslint-config": "0.3.0",
94
- "@particle-network/icons": "0.3.0-beta.1",
94
+ "@particle-network/icons": "0.3.0-beta.4",
95
95
  "@particle-network/lintstaged-config": "0.1.0"
96
96
  },
97
97
  "overrides": {