@storybook/react-native-ui-lite 9.1.0 → 9.1.1-alpha.1

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.d.ts CHANGED
@@ -113,4 +113,4 @@ declare const Layout: ({ storyHash, story, children, }: {
113
113
  children: ReactNode | ReactNode[];
114
114
  }) => react_jsx_runtime.JSX.Element;
115
115
 
116
- export { ComponentNode, Explorer, ExplorerProps, GroupNode, Layout, LeafNodeStyleWrapper, LiteUI, Node, NodeProps$1 as NodeProps, RootNode, RootNodeText, Sidebar, SidebarProps, StoryNode, Tree, useCombination };
116
+ export { ComponentNode, Explorer, type ExplorerProps, GroupNode, Layout, LeafNodeStyleWrapper, LiteUI, Node, type NodeProps$1 as NodeProps, RootNode, RootNodeText, Sidebar, type SidebarProps, StoryNode, Tree, useCombination };
package/dist/index.js CHANGED
@@ -27,8 +27,8 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
27
27
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
28
 
29
29
  // src/index.tsx
30
- var src_exports = {};
31
- __export(src_exports, {
30
+ var index_exports = {};
31
+ __export(index_exports, {
32
32
  ComponentNode: () => ComponentNode,
33
33
  Explorer: () => Explorer,
34
34
  GroupNode: () => GroupNode,
@@ -43,7 +43,7 @@ __export(src_exports, {
43
43
  Tree: () => Tree,
44
44
  useCombination: () => useCombination
45
45
  });
46
- module.exports = __toCommonJS(src_exports);
46
+ module.exports = __toCommonJS(index_exports);
47
47
 
48
48
  // src/TreeNode.tsx
49
49
  var import_react_native_theming2 = require("@storybook/react-native-theming");
@@ -621,12 +621,9 @@ var Tree = import_react4.default.memo(function Tree2({ isMain, refId, data, stat
621
621
  () => Object.keys(data).reduce(
622
622
  (acc, id) => {
623
623
  const item = data[id];
624
- if (item.type === "root")
625
- acc[0].push(id);
626
- else if (!item.parent)
627
- acc[1].push(id);
628
- if (item.type === "root" && item.startCollapsed)
629
- acc[2][id] = false;
624
+ if (item.type === "root") acc[0].push(id);
625
+ else if (!item.parent) acc[1].push(id);
626
+ if (item.type === "root" && item.startCollapsed) acc[2][id] = false;
630
627
  return acc;
631
628
  },
632
629
  [[], [], {}]
@@ -647,16 +644,12 @@ var Tree = import_react4.default.memo(function Tree2({ isMain, refId, data, stat
647
644
  const singleStoryComponentIds = (0, import_react4.useMemo)(() => {
648
645
  return Object.keys(data).filter((id) => {
649
646
  const entry = data[id];
650
- if (entry.type !== "component")
651
- return false;
647
+ if (entry.type !== "component") return false;
652
648
  const { children = [], name } = entry;
653
- if (children.length !== 1)
654
- return false;
649
+ if (children.length !== 1) return false;
655
650
  const onlyChild = data[children[0]];
656
- if (onlyChild.type === "docs")
657
- return true;
658
- if (onlyChild.type === "story")
659
- return (0, import_react_native_ui_common.isStoryHoistable)(onlyChild.name, name);
651
+ if (onlyChild.type === "docs") return true;
652
+ if (onlyChild.type === "story") return (0, import_react_native_ui_common.isStoryHoistable)(onlyChild.name, name);
660
653
  return false;
661
654
  });
662
655
  }, [data]);
@@ -1006,8 +999,7 @@ var Search = import_react8.default.memo(function Search2({ children, dataset, se
1006
999
  const getResults = (0, import_react8.useCallback)(
1007
1000
  (input2) => {
1008
1001
  const fuse = makeFuse();
1009
- if (!input2)
1010
- return [];
1002
+ if (!input2) return [];
1011
1003
  let results2 = [];
1012
1004
  const resultIds = /* @__PURE__ */ new Set();
1013
1005
  const distinctResults = fuse.search(input2).filter(({ item }) => {
@@ -1150,8 +1142,7 @@ var RecentlyOpenedTitle = import_react_native_theming6.styled.View(({ theme }) =
1150
1142
  }));
1151
1143
  var Highlight = import_react9.default.memo(
1152
1144
  function Highlight2({ children, match }) {
1153
- if (!match)
1154
- return children;
1145
+ if (!match) return children;
1155
1146
  const { value, indices } = match;
1156
1147
  const { nodes: result } = indices.reduce(
1157
1148
  ({ cursor, nodes }, [start, end], index, { length }) => {
@@ -1739,8 +1730,7 @@ var BrandLogo = ({ theme }) => {
1739
1730
  import_react_native8.TouchableOpacity,
1740
1731
  {
1741
1732
  onPress: () => {
1742
- if (theme.brand.url)
1743
- import_react_native8.Linking.openURL(theme.brand.url);
1733
+ if (theme.brand.url) import_react_native8.Linking.openURL(theme.brand.url);
1744
1734
  },
1745
1735
  children: image
1746
1736
  }
@@ -1764,8 +1754,7 @@ var BrandTitle = ({ theme }) => {
1764
1754
  import_react_native8.TouchableOpacity,
1765
1755
  {
1766
1756
  onPress: () => {
1767
- if (theme.brand.url)
1768
- import_react_native8.Linking.openURL(theme.brand.url);
1757
+ if (theme.brand.url) import_react_native8.Linking.openURL(theme.brand.url);
1769
1758
  },
1770
1759
  children: title
1771
1760
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@storybook/react-native-ui-lite",
3
- "version": "9.1.0",
3
+ "version": "9.1.1-alpha.1",
4
4
  "description": "lightweight ui components for react native storybook",
5
5
  "keywords": [
6
6
  "react",
@@ -54,13 +54,13 @@
54
54
  "jest": "^29.7.0",
55
55
  "react-test-renderer": "^19.1.0",
56
56
  "ts-dedent": "^2.2.0",
57
- "tsup": "^7.2.0",
57
+ "tsup": "^8.5.0",
58
58
  "typescript": "~5.8.3"
59
59
  },
60
60
  "dependencies": {
61
- "@storybook/react": "^9.1.0",
62
- "@storybook/react-native-theming": "^9.1.0",
63
- "@storybook/react-native-ui-common": "^9.1.0",
61
+ "@storybook/react": "^9.1.2",
62
+ "@storybook/react-native-theming": "^9.1.1-alpha.1",
63
+ "@storybook/react-native-ui-common": "^9.1.1-alpha.1",
64
64
  "fuse.js": "^7.0.0",
65
65
  "memoizerific": "^1.11.3",
66
66
  "polished": "^4.3.1",
@@ -77,5 +77,5 @@
77
77
  "publishConfig": {
78
78
  "access": "public"
79
79
  },
80
- "gitHead": "38124888d92766d2a5b8c2bfa0fd283bb384a4cd"
80
+ "gitHead": "cc38bfb53177171ffb92d228c0bcde0e4d01d767"
81
81
  }