@swiftbrowser/react 0.5.2 → 0.5.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/dist/island.d.ts CHANGED
@@ -18,8 +18,24 @@ export interface SwiftUIViewProps {
18
18
  contexts?: readonly Context<unknown>[];
19
19
  /** The asset catalog manifest for `Image(name:)` and catalog colors (see `mount`). */
20
20
  assets?: AssetCatalog;
21
+ /**
22
+ * Insets the views keep clear of, as a device's status bar and home
23
+ * indicator: a navigation bar sits below `top` (its background reaching
24
+ * into it), a list starts below it. A number is the top inset. By default
25
+ * a `fill` island keeps `WINDOW_TOP_INSET` at the top, as SwiftUI keeps its
26
+ * bars off a window's edge where there is no status bar; `content` has none.
27
+ */
28
+ safeArea?: number | Partial<SafeAreaInsets>;
21
29
  className?: string;
22
30
  style?: CSSProperties;
23
31
  }
24
- export declare function SwiftUIView({ children, fit, colorScheme, dynamicTypeSize, contexts, assets, className, style, }: SwiftUIViewProps): ReactNode;
32
+ interface SafeAreaInsets {
33
+ top: number;
34
+ leading: number;
35
+ bottom: number;
36
+ trailing: number;
37
+ }
38
+ export declare function insetsOf(safeArea: SwiftUIViewProps['safeArea'], fit: 'fill' | 'content'): SafeAreaInsets;
39
+ export declare function SwiftUIView({ children, fit, colorScheme, dynamicTypeSize, contexts, assets, safeArea, className, style, }: SwiftUIViewProps): ReactNode;
40
+ export {};
25
41
  //# sourceMappingURL=island.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"island.d.ts","sourceRoot":"","sources":["../src/island.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,KAAK,EAAE,WAAW,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AAEnF,OAAO,EAA2B,KAAK,aAAa,EAAE,KAAK,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAIlG,MAAM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O,CAAC,cAAc,CAAC,CAAC;IAC5C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,aAAa,CAAC;CACvB;AAED,UAAU,cAAc;IACtB,GAAG,EAAE,MAAM,CAAC;IACZ,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;CAClB;AAKD,wBAAgB,QAAQ,CAAC,QAAQ,EAAE,gBAAgB,CAAC,UAAU,CAAC,EAAE,GAAG,EAAE,MAAM,GAAG,SAAS,GAAG,cAAc,CAGxG;AAED,wBAAgB,WAAW,CAAC,EAC1B,QAAQ,EACR,GAAY,EACZ,WAAqB,EACrB,eAAyB,EACzB,QAAQ,EACR,MAAM,EACN,QAAQ,EACR,SAAS,EACT,KAAK,GACN,EAAE,gBAAgB,GAAG,SAAS,CAkD9B"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@swiftbrowser/react",
3
- "version": "0.5.2",
3
+ "version": "0.5.3",
4
4
  "type": "module",
5
5
  "description": "SwiftUI's components for React: a react-reconciler host that emits SwiftBrowser render ops into the @swiftbrowser/web renderer, so a pure React/TypeScript web app gets the same iOS UI as a SwiftUI app in the browser.",
6
6
  "repository": {
@@ -29,7 +29,7 @@
29
29
  "test:unit": "vitest run"
30
30
  },
31
31
  "dependencies": {
32
- "@swiftbrowser/web": "0.5.2"
32
+ "@swiftbrowser/web": "0.5.3"
33
33
  },
34
34
  "peerDependencies": {
35
35
  "react": "^19.0.0",