@mlightcad/cad-viewer 1.5.4 → 1.5.6

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.
Files changed (40) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +3 -0
  3. package/dist/app/register.d.ts.map +1 -1
  4. package/dist/app/store.d.ts +0 -1
  5. package/dist/app/store.d.ts.map +1 -1
  6. package/dist/cad-viewer.css +1 -0
  7. package/dist/{index.d.ts → cad-viewer.d.ts} +1 -1
  8. package/dist/{index.js → cad-viewer.js} +9890 -9257
  9. package/dist/component/MlCadViewer.vue.d.ts +23 -1
  10. package/dist/component/MlCadViewer.vue.d.ts.map +1 -1
  11. package/dist/component/common/MlFontFileReader.vue.d.ts +3 -0
  12. package/dist/component/common/MlFontFileReader.vue.d.ts.map +1 -0
  13. package/dist/component/common/index.d.ts +1 -0
  14. package/dist/component/common/index.d.ts.map +1 -1
  15. package/dist/component/dialog/MlReplacementDlg.vue.d.ts.map +1 -1
  16. package/dist/component/layout/MlMainMenu.vue.d.ts.map +1 -1
  17. package/dist/component/layout/MlToolBars.vue.d.ts.map +1 -1
  18. package/dist/component/ribbon/MlRibbonCommands.vue.d.ts.map +1 -1
  19. package/dist/component/ribbon/MlRibbonFileName.vue.d.ts +15 -0
  20. package/dist/component/ribbon/MlRibbonFileName.vue.d.ts.map +1 -0
  21. package/dist/composable/index.d.ts +1 -2
  22. package/dist/composable/index.d.ts.map +1 -1
  23. package/dist/composable/useDocument.d.ts +85 -0
  24. package/dist/composable/useDocument.d.ts.map +1 -0
  25. package/dist/composable/useHover.d.ts +332 -18
  26. package/dist/composable/useHover.d.ts.map +1 -1
  27. package/dist/locale/en/dialog.d.ts +1 -0
  28. package/dist/locale/en/dialog.d.ts.map +1 -1
  29. package/dist/locale/en/main.d.ts +2 -0
  30. package/dist/locale/en/main.d.ts.map +1 -1
  31. package/dist/locale/zh/dialog.d.ts +1 -0
  32. package/dist/locale/zh/dialog.d.ts.map +1 -1
  33. package/dist/locale/zh/main.d.ts +2 -0
  34. package/dist/locale/zh/main.d.ts.map +1 -1
  35. package/package.json +17 -17
  36. package/dist/composable/useDocOpenMode.d.ts +0 -19
  37. package/dist/composable/useDocOpenMode.d.ts.map +0 -1
  38. package/dist/composable/useDocumentOpening.d.ts +0 -9
  39. package/dist/composable/useDocumentOpening.d.ts.map +0 -1
  40. package/dist/index.css +0 -1
@@ -1,4 +1,4 @@
1
- import { AcEdOpenMode } from '@mlightcad/cad-simple-viewer';
1
+ import { AcApOpenViewMode, AcEdOpenMode } from '@mlightcad/cad-simple-viewer';
2
2
  import { LocaleProp } from '../locale';
3
3
  interface Props {
4
4
  /** Language locale for internationalization ('en', 'zh', or 'default') */
@@ -32,6 +32,22 @@ interface Props {
32
32
  * - Write (8): Full read/write access, compatible with Review and Read
33
33
  */
34
34
  mode?: AcEdOpenMode;
35
+ /**
36
+ * Whether entities on non-plottable ("no-plot") layers are drawn.
37
+ * When omitted, {@link AcApDocManager} defaults to `false` (web viewer semantics).
38
+ */
39
+ drawNoPlotLayers?: boolean;
40
+ /**
41
+ * Whether to render entities incrementally while a drawing is opening.
42
+ * When omitted, {@link AcApDocManager} defaults to `false`.
43
+ */
44
+ progressiveRendering?: boolean;
45
+ /**
46
+ * How to frame the view when the document finishes opening.
47
+ * When omitted, Read and Review use {@link AcApOpenViewMode.Extents};
48
+ * Write uses {@link AcApOpenViewMode.Saved}.
49
+ */
50
+ openViewMode?: AcApOpenViewMode;
35
51
  }
36
52
  declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<Props>, {
37
53
  locale: string;
@@ -43,6 +59,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
43
59
  useMainThreadDraw: boolean;
44
60
  theme: string;
45
61
  mode: AcEdOpenMode;
62
+ progressiveRendering: boolean;
63
+ openViewMode: undefined;
46
64
  }>>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
47
65
  create: () => void;
48
66
  destroy: () => void;
@@ -56,6 +74,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
56
74
  useMainThreadDraw: boolean;
57
75
  theme: string;
58
76
  mode: AcEdOpenMode;
77
+ progressiveRendering: boolean;
78
+ openViewMode: undefined;
59
79
  }>>> & Readonly<{
60
80
  onCreate?: (() => any) | undefined;
61
81
  onDestroy?: (() => any) | undefined;
@@ -69,6 +89,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
69
89
  baseUrl: string;
70
90
  htmlViewerRuntimeUrl: string | URL;
71
91
  useMainThreadDraw: boolean;
92
+ progressiveRendering: boolean;
93
+ openViewMode: AcApOpenViewMode;
72
94
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
73
95
  export default _default;
74
96
  type __VLS_WithDefaults<P, D> = {
@@ -1 +1 @@
1
- {"version":3,"file":"MlCadViewer.vue.d.ts","sourceRoot":"","sources":["../../src/component/MlCadViewer.vue"],"names":[],"mappings":"AA0CA;AAiyBA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsCG;AACH,OAAO,EAKL,YAAY,EAEb,MAAM,8BAA8B,CAAA;AAoBrC,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAA;AA4BtC,UAAU,KAAK;IACb,0EAA0E;IAC1E,MAAM,CAAC,EAAE,UAAU,CAAA;IACnB,uEAAuE;IACvE,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,qFAAqF;IACrF,SAAS,CAAC,EAAE,IAAI,CAAA;IAChB,yEAAyE;IACzE,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,uGAAuG;IACvG,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB;;;;OAIG;IACH,oBAAoB,CAAC,EAAE,MAAM,GAAG,GAAG,CAAA;IACnC;;;;OAIG;IACH,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B,kCAAkC;IAClC,KAAK,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M,CAAC,CAAC,GAAG,CAAC,SAAS,MAAM,CAAC,GAC7C,mBAAmB,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG;QAAE,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,CAAA;KAAC,CAAC,GAC5C,CAAC,CAAC,CAAC,CAAC;CACP,CAAC;AACF,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AACjE,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC;AACF,KAAK,mBAAmB,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
@@ -0,0 +1,3 @@
1
+ declare const _default: import('vue').DefineComponent<{}, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
2
+ export default _default;
3
+ //# sourceMappingURL=MlFontFileReader.vue.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MlFontFileReader.vue.d.ts","sourceRoot":"","sources":["../../../src/component/common/MlFontFileReader.vue"],"names":[],"mappings":"AASA;;AAwGA,wBAKG"}
@@ -12,6 +12,7 @@ export { default as MlHatchPatternPanel } from './MlHatchPatternPanel.vue';
12
12
  export { default as MlLineWeightSelect } from './MlLineWeightSelect.vue';
13
13
  export { default as MlLayerSelect } from './MlLayerSelect.vue';
14
14
  export { default as MlFileReader } from './MlFileReader.vue';
15
+ export { default as MlFontFileReader } from './MlFontFileReader.vue';
15
16
  export { default as MlLineTypeSelect } from './MlLineTypeSelect.vue';
16
17
  export { default as MlHatchPatternDropdown } from './MlHatchPatternDropdown.vue';
17
18
  export { default as MlSysVarToggleButton } from './MlSysVarToggleButton.vue';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/component/common/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sCAAsC,EAAE,MAAM,0CAA0C,CAAA;AACjG,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,oBAAoB,CAAA;AAC5D,OAAO,EAAE,OAAO,IAAI,sBAAsB,EAAE,MAAM,8BAA8B,CAAA;AAChF,OAAO,EAAE,OAAO,IAAI,iBAAiB,EAAE,MAAM,yBAAyB,CAAA;AACtE,OAAO,EAAE,OAAO,IAAI,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAClE,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,0BAA0B,CAAA;AACxE,OAAO,EAAE,OAAO,IAAI,qBAAqB,EAAE,MAAM,6BAA6B,CAAA;AAC9E,OAAO,EAAE,OAAO,IAAI,iBAAiB,EAAE,MAAM,yBAAyB,CAAA;AACtE,OAAO,EAAE,OAAO,IAAI,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAClE,OAAO,EAAE,OAAO,IAAI,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAClE,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,2BAA2B,CAAA;AAC1E,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,0BAA0B,CAAA;AACxE,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,qBAAqB,CAAA;AAC9D,OAAO,EA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IAAI,YAAY,EAAE,MAAM,oBAAoB,CAAA;AAC5D,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,wBAAwB,CAAA;AACpE,OAAO,EAAE,OAAO,IAAI,gBAAgB,EAAE,MAAM,wBAAwB,CAAA;AACpE,OAAO,EAAE,OAAO,IAAI,sBAAsB,EAAE,MAAM,8BAA8B,CAAA;AAChF,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAE,MAAM,4BAA4B,CAAA;AAC5E,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,sBAAsB,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"MlReplacementDlg.vue.d.ts","sourceRoot":"","sources":["../../../src/component/dialog/MlReplacementDlg.vue"],"names":[],"mappings":"AAsLA;;AAk/BA,wBAKG"}
1
+ {"version":3,"file":"MlReplacementDlg.vue.d.ts","sourceRoot":"","sources":["../../../src/component/dialog/MlReplacementDlg.vue"],"names":[],"mappings":"AAiNA;;AA4uCA,wBAKG"}
@@ -1 +1 @@
1
- {"version":3,"file":"MlMainMenu.vue.d.ts","sourceRoot":"","sources":["../../../src/component/layout/MlMainMenu.vue"],"names":[],"mappings":"AAkDA;;AAwaA,wBAKG"}
1
+ {"version":3,"file":"MlMainMenu.vue.d.ts","sourceRoot":"","sources":["../../../src/component/layout/MlMainMenu.vue"],"names":[],"mappings":"AAuDA;;AAkeA,wBAKG"}
@@ -1 +1 @@
1
- {"version":3,"file":"MlToolBars.vue.d.ts","sourceRoot":"","sources":["../../../src/component/layout/MlToolBars.vue"],"names":[],"mappings":";AA4dA,wBAKG"}
1
+ {"version":3,"file":"MlToolBars.vue.d.ts","sourceRoot":"","sources":["../../../src/component/layout/MlToolBars.vue"],"names":[],"mappings":";AAkdA,wBAKG"}
@@ -1 +1 @@
1
- {"version":3,"file":"MlRibbonCommands.vue.d.ts","sourceRoot":"","sources":["../../../src/component/ribbon/MlRibbonCommands.vue"],"names":[],"mappings":"AA6lDA,OAAO,6BAA6B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Ac,CAAA;AAmEzC,UAAU,KAAK;IACb,aAAa,CAAC,EAAE,UAAU,CAAA;CAC3B;;;;;;mBADiB,UAAU;;AAylD5B,wBAMG;AAEH,KAAK,kBAAkB,CAAC,CAAC,EAAE,CAAC,IAAI;KAC9B,CAAC,IAAI,MAAM,IAAI,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,GAAG,CAAC,SAAS,MAAM,CAAC,GAC7C,mBAAmB,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG;QAAE,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,CAAA;KAAC,CAAC,GAC5C,CAAC,CAAC,CAAC,CAAC;CACP,CAAC;AACF,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AACjE,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC;AACF,KAAK,mBAAmB,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC"}
@@ -0,0 +1,15 @@
1
+ interface Props {
2
+ containerEl?: HTMLElement | null;
3
+ }
4
+ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<__VLS_TypePropsToOption<Props>>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_TypePropsToOption<Props>>> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
5
+ export default _default;
6
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
7
+ type __VLS_TypePropsToOption<T> = {
8
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
9
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
10
+ } : {
11
+ type: import('vue').PropType<T[K]>;
12
+ required: true;
13
+ };
14
+ };
15
+ //# sourceMappingURL=MlRibbonFileName.vue.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"MlRibbonFileName.vue.d.ts","sourceRoot":"","sources":["../../../src/component/ribbon/MlRibbonFileName.vue"],"names":[],"mappings":"AAOA;AAiJA,UAAU,KAAK;IACb,WAAW,CAAC,EAAE,WAAW,GAAG,IAAI,CAAA;CACjC;;AAuJD,wBAMG;AAEH,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AACjE,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
@@ -2,8 +2,7 @@ export * from './useCommands';
2
2
  export * from './useCurrentPos';
3
3
  export * from './useDark';
4
4
  export * from './useDialogManager';
5
- export * from './useDocumentOpening';
6
- export * from './useDocOpenMode';
5
+ export * from './useDocument';
7
6
  export * from './useEntityDrawStyle';
8
7
  export * from './useFileTypes';
9
8
  export * from './useHover';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/composable/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAA;AAC7B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,WAAW,CAAA;AACzB,cAAc,oBAAoB,CAAA;AAClC,cAAc,sBAAsB,CAAA;AACpC,cAAc,kBAAkB,CAAA;AAChC,cAAc,sBAAsB,CAAA;AACpC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,YAAY,CAAA;AAC1B,cAAc,aAAa,CAAA;AAC3B,cAAc,cAAc,CAAA;AAC5B,cAAc,aAAa,CAAA;AAC3B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,yBAAyB,CAAA;AACvC,cAAc,mBAAmB,CAAA;AACjC,cAAc,eAAe,CAAA;AAC7B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,gBAAgB,CAAA;AAC9B,cAAc,eAAe,CAAA;AAC7B,cAAc,kBAAkB,CAAA;AAChC,cAAc,0BAA0B,CAAA;AACxC,cAAc,iBAAiB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/composable/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAA;AAC7B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,WAAW,CAAA;AACzB,cAAc,oBAAoB,CAAA;AAClC,cAAc,eAAe,CAAA;AAC7B,cAAc,sBAAsB,CAAA;AACpC,cAAc,gBAAgB,CAAA;AAC9B,cAAc,YAAY,CAAA;AAC1B,cAAc,aAAa,CAAA;AAC3B,cAAc,cAAc,CAAA;AAC5B,cAAc,aAAa,CAAA;AAC3B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,yBAAyB,CAAA;AACvC,cAAc,mBAAmB,CAAA;AACjC,cAAc,eAAe,CAAA;AAC7B,cAAc,iBAAiB,CAAA;AAC/B,cAAc,gBAAgB,CAAA;AAC9B,cAAc,eAAe,CAAA;AAC7B,cAAc,kBAAkB,CAAA;AAChC,cAAc,0BAA0B,CAAA;AACxC,cAAc,iBAAiB,CAAA"}
@@ -0,0 +1,85 @@
1
+ import { AcEdOpenMode } from '@mlightcad/cad-simple-viewer';
2
+ import { ComputedRef, DeepReadonly, Ref } from 'vue';
3
+ /**
4
+ * Reactive view of the active CAD document and its open lifecycle.
5
+ *
6
+ * Returned by {@link useDocument}. All refs are shared module singletons, so
7
+ * every caller observes the same document state.
8
+ */
9
+ export interface UseDocumentReturn {
10
+ /**
11
+ * Whether a document open operation is currently in progress.
12
+ *
13
+ * Becomes `true` when {@link AcApDocManager.events.documentToBeOpened} fires
14
+ * or when {@link beginDocumentOpening} is called manually, and becomes
15
+ * `false` when the document is activated, opening fails, or
16
+ * {@link endDocumentOpening} is called manually.
17
+ */
18
+ isDocumentOpening: DeepReadonly<Ref<boolean>>;
19
+ /**
20
+ * Current or pending document access mode.
21
+ *
22
+ * During an open request this reflects the mode carried by
23
+ * {@link AcDbDocumentEventArgs.mode} from `documentToBeOpened`. After
24
+ * activation it mirrors {@link AcApDocument.openMode}.
25
+ */
26
+ openMode: DeepReadonly<Ref<AcEdOpenMode>>;
27
+ /**
28
+ * File name of the active document.
29
+ *
30
+ * Mirrors {@link AcApDocument.fileName}. Empty for a new untitled document
31
+ * that has not been saved or opened from disk.
32
+ */
33
+ fileName: DeepReadonly<Ref<string>>;
34
+ /**
35
+ * Display title of the active document.
36
+ *
37
+ * Mirrors {@link AcApDocument.docTitle}. For a new document this is
38
+ * typically `"Untitled"` until a file is opened.
39
+ */
40
+ docTitle: DeepReadonly<Ref<string>>;
41
+ /**
42
+ * User-facing document label for UI display.
43
+ *
44
+ * Resolves to {@link docTitle} when present, otherwise falls back to
45
+ * {@link fileName}.
46
+ */
47
+ displayName: ComputedRef<string>;
48
+ /**
49
+ * Marks the viewer as entering a document open operation.
50
+ *
51
+ * Prefer relying on {@link AcApDocManager.events.documentToBeOpened} when
52
+ * possible. Call this manually only for open flows that bypass the manager
53
+ * events but still need UI affordances such as disabling the ribbon.
54
+ */
55
+ beginDocumentOpening: () => void;
56
+ /**
57
+ * Marks the viewer as leaving a document open operation.
58
+ *
59
+ * Prefer relying on {@link AcApDocManager.events.documentActivated} or the
60
+ * `failed-to-open-file` event. Call this manually to pair with
61
+ * {@link beginDocumentOpening} in custom open handlers.
62
+ */
63
+ endDocumentOpening: () => void;
64
+ }
65
+ /**
66
+ * Tracks the active CAD document and its open lifecycle for UI consumers.
67
+ *
68
+ * This composable centralizes reactive document metadata from
69
+ * {@link AcApDocManager} and {@link AcApDocument}, including:
70
+ * - Current or pending document open mode
71
+ * - Whether a document open operation is in progress
72
+ * - Current document file name and display title
73
+ *
74
+ * Behavior:
75
+ * - Initializes from the currently active document once the viewer exists
76
+ * - Retries binding after mount when the viewer has not been created yet
77
+ * - Updates {@link openMode} as soon as `documentToBeOpened` fires
78
+ * - Synchronizes {@link fileName}, {@link docTitle}, and {@link openMode}
79
+ * when `documentActivated` fires
80
+ * - Clears the opening state when `failed-to-open-file` is emitted
81
+ *
82
+ * @returns Shared reactive document state and manual open-state helpers
83
+ */
84
+ export declare function useDocument(): UseDocumentReturn;
85
+ //# sourceMappingURL=useDocument.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useDocument.d.ts","sourceRoot":"","sources":["../../src/composable/useDocument.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,YAAY,EAEb,MAAM,8BAA8B,CAAA;AACrC,OAAO,EAAY,KAAK,WAAW,EAAE,KAAK,YAAY,EAAuB,KAAK,GAAG,EAAM,MAAM,KAAK,CAAA;AAEtG;;;;;GAKG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;;;;;OAOG;IACH,iBAAiB,EAAE,YAAY,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAA;IAE7C;;;;;;OAMG;IACH,QAAQ,EAAE,YAAY,CAAC,GAAG,CAAC,YAAY,CAAC,CAAC,CAAA;IAEzC;;;;;OAKG;IACH,QAAQ,EAAE,YAAY,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,CAAA;IAEnC;;;;;OAKG;IACH,QAAQ,EAAE,YAAY,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,CAAA;IAEnC;;;;;OAKG;IACH,WAAW,EAAE,WAAW,CAAC,MAAM,CAAC,CAAA;IAEhC;;;;;;OAMG;IACH,oBAAoB,EAAE,MAAM,IAAI,CAAA;IAEhC;;;;;;OAMG;IACH,kBAAkB,EAAE,MAAM,IAAI,CAAA;CAC/B;AAsJD;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,WAAW,IAAI,iBAAiB,CAgB/C"}