@brucesantos/design-space 0.11.0 → 0.12.0

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.
@@ -1,3 +1,4 @@
1
+ import { RefObject } from 'react';
1
2
  import { DesignSpaceLocation } from '../controls/state.js';
2
3
  import { FrameShortcut } from '../frame/index.js';
3
4
  import { ViewportSetting } from '../types/index.js';
@@ -15,5 +16,7 @@ export type CanvasProps = {
15
16
  resizing: boolean;
16
17
  onFrameNavigate: (url: string, replace: boolean) => void;
17
18
  onShortcut: (key: FrameShortcut) => void;
19
+ /** O `<iframe>`, com o dono no chrome: "Abrir em nova janela" lê o endereço dele. */
20
+ frameRef: RefObject<HTMLIFrameElement | null>;
18
21
  };
19
- export declare function Canvas({ location, viewport, zoom, title, resizing, onFrameNavigate, onShortcut, onEffectiveZoom, }: CanvasProps): import("react").JSX.Element;
22
+ export declare function Canvas({ location, viewport, zoom, title, resizing, onFrameNavigate, onShortcut, onEffectiveZoom, frameRef, }: CanvasProps): import("react").JSX.Element;
@@ -21,6 +21,8 @@ export type TopbarProps = {
21
21
  onZoom: (zoom: number) => void;
22
22
  onHighlight: () => void;
23
23
  onCleanReview: () => void;
24
+ /** Abre o quadro sozinho numa janela própria, para ferramenta de captura. */
25
+ onOpenFrame: () => void;
24
26
  onToggleTheme: () => void;
25
27
  };
26
- export declare function Topbar({ productName, viewportId, viewport, zoom, rotated, highlight, theme, issues, linkUrl, onViewport, onRotate, onZoom, onHighlight, onCleanReview, onToggleTheme, }: TopbarProps): import("react").JSX.Element;
28
+ export declare function Topbar({ productName, viewportId, viewport, zoom, rotated, highlight, theme, issues, linkUrl, onViewport, onRotate, onZoom, onHighlight, onCleanReview, onOpenFrame, onToggleTheme, }: TopbarProps): import("react").JSX.Element;
@@ -2,7 +2,7 @@
2
2
  * Ícones do chrome: traço simples, `currentColor`, 16px. Sem texto, sem cor.
3
3
  * Todo ícone é decorativo; o nome acessível fica no botão que o contém.
4
4
  */
5
- export type IconName = "mobile" | "tablet" | "desktop" | "fit" | "rotate" | "minus" | "plus" | "link" | "arrow-up-right" | "check" | "fullscreen" | "components" | "sun" | "moon" | "panel" | "alert" | "chevron" | "search" | "copy";
5
+ export type IconName = "mobile" | "tablet" | "desktop" | "fit" | "rotate" | "minus" | "plus" | "link" | "arrow-up-right" | "check" | "fullscreen" | "components" | "external" | "sun" | "moon" | "panel" | "alert" | "chevron" | "search" | "copy";
6
6
  export declare function Icon({ name, size }: {
7
7
  name: IconName;
8
8
  size?: number;
@@ -16,6 +16,8 @@ export type Labels = {
16
16
  copyPrompt: string;
17
17
  cleanReview: string;
18
18
  highlight: string;
19
+ /** Abre o quadro sozinho, sem o chrome, numa janela própria. */
20
+ openFrame: string;
19
21
  lightMode: string;
20
22
  darkMode: string;
21
23
  engineVersion: (version: string) => string;
package/dist/testing.js CHANGED
@@ -1,4 +1,4 @@
1
- import { o as s, v as t, B as i, A as a, k as n } from "./index-Dv-W-bL0.js";
1
+ import { o as s, v as t, D as i, B as a, k as n } from "./index-rWBjjVMg.js";
2
2
  function c(o = "http://localhost:5173") {
3
3
  const r = typeof process < "u" ? process.env : {};
4
4
  return (r.PREVIEW_URL || r.BASE_URL || o).replace(/\/$/, "");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brucesantos/design-space",
3
- "version": "0.11.0",
3
+ "version": "0.12.0",
4
4
  "description": "Motor neutro do Bananas Design Space: telas como rotas com variações, catálogo de componentes, chrome em preto e branco com a UI do produto num iframe, deep links e controles de persona/viewport/rede. Não contém UI de cliente.",
5
5
  "type": "module",
6
6
  "license": "MIT",