ooxml-ui 1.1.0 → 1.2.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.
- package/README.md +38 -36
- package/custom-elements.json +211 -4
- package/dist/chrome/ruler.d.ts +60 -2
- package/dist/chrome/ruler.d.ts.map +1 -1
- package/dist/chrome/status-bar.d.ts +3 -1
- package/dist/chrome/status-bar.d.ts.map +1 -1
- package/dist/{chunk-M5DTJSOV.js → chunk-7FNDOWTX.js} +393 -15
- package/dist/{chunk-KVKKXRL7.js → chunk-AYXFLBSV.js} +92 -13
- package/dist/{chunk-X7RINDJQ.js → chunk-JAJFLFAV.js} +1 -1
- package/dist/{chunk-3FPW7M6U.js → chunk-VUB44CAJ.js} +1 -1
- package/dist/{chunk-JFJXBYRD.js → chunk-XNCWB2X6.js} +5 -0
- package/dist/{chunk-BEN3453I.js → chunk-Y2E22JVO.js} +1 -1
- package/dist/{chunk-USDLALB5.js → chunk-YK2DPYMU.js} +1 -1
- package/dist/{chunk-ZU7GX4SY.js → chunk-YP5S7DTT.js} +6 -5
- package/dist/comments/comments-pane.d.ts +116 -0
- package/dist/comments/comments-pane.d.ts.map +1 -0
- package/dist/comments/types.d.ts +80 -0
- package/dist/comments/types.d.ts.map +1 -0
- package/dist/controls.d.ts +4 -2
- package/dist/controls.d.ts.map +1 -1
- package/dist/controls.js +4 -4
- package/dist/docx/comments-panel.d.ts +8 -1
- package/dist/docx/image-media.d.ts +1 -1
- package/dist/docx/locales/en-ribbon.d.ts +1 -0
- package/dist/docx/locales/en.d.ts +1 -0
- package/dist/docx/localization-strings.d.ts +1 -0
- package/dist/docx/localization.d.ts +7 -0
- package/dist/docx/print-layout.d.ts +2 -2
- package/dist/docx/print-picture.d.ts +12 -0
- package/dist/docx/review-controller.d.ts +2 -0
- package/dist/docx/ruler.d.ts +7 -10
- package/dist/docx.js +282 -322
- package/dist/form/gradient-preset-gallery.d.ts +2 -2
- package/dist/index.d.ts +1 -1
- package/dist/index.js +8 -8
- package/dist/pptx/{chart-3d-view-scene-2KRQ5667.mjs → chart-3d-view-scene-6B5TOWB6.mjs} +3 -3
- package/dist/pptx/{chart-3d-view-scene-36DMZWZ3.cjs → chart-3d-view-scene-MJ6YNT56.cjs} +37 -37
- package/dist/pptx/{chunk-YOGDIDPB.mjs → chunk-AWKKC3VW.mjs} +8 -2
- package/dist/pptx/{chunk-CJU4P5FT.cjs → chunk-STKGUT5S.cjs} +18 -12
- package/dist/pptx/{chunk-YHA6XAB3.cjs → chunk-XIQMFSNG.cjs} +1 -1
- package/dist/pptx/{chunk-YARCML7O.mjs → chunk-XQVKQD5Z.mjs} +294 -265
- package/dist/pptx/{chunk-Y2W4SZER.mjs → chunk-YI5LH5NN.mjs} +479 -336
- package/dist/pptx/{chunk-ADOC5JLI.mjs → chunk-YMTQLZ2I.mjs} +1 -1
- package/dist/pptx/{chunk-AIL3BNZS.cjs → chunk-YRHK45AB.cjs} +301 -265
- package/dist/pptx/{chunk-KPZWYF44.cjs → chunk-ZK344LOB.cjs} +629 -479
- package/dist/pptx/dom/elements/chart.d.ts +2 -3
- package/dist/pptx/dom/elements/chart.d.ts.map +1 -1
- package/dist/pptx/dom/elements/table.d.ts.map +1 -1
- package/dist/pptx/dom/index.cjs +254 -243
- package/dist/pptx/dom/index.mjs +26 -15
- package/dist/pptx/export/html2canvas-clone.cjs +2 -2
- package/dist/pptx/export/html2canvas-clone.mjs +1 -1
- package/dist/pptx/index.cjs +3025 -2993
- package/dist/pptx/index.mjs +4 -4
- package/dist/pptx/render/chart-axis-range.d.ts +7 -0
- package/dist/pptx/render/chart-axis-range.d.ts.map +1 -1
- package/dist/pptx/render/chart-axis-render.d.ts +3 -1
- package/dist/pptx/render/chart-axis-render.d.ts.map +1 -1
- package/dist/pptx/render/chart-axis-style.d.ts +5 -0
- package/dist/pptx/render/chart-axis-style.d.ts.map +1 -1
- package/dist/pptx/render/chart-axis.d.ts +1 -1
- package/dist/pptx/render/chart-axis.d.ts.map +1 -1
- package/dist/pptx/render/chart-cartesian-axes.d.ts.map +1 -1
- package/dist/pptx/render/chart-cartesian-bars.d.ts +3 -3
- package/dist/pptx/render/chart-cartesian-bars.d.ts.map +1 -1
- package/dist/pptx/render/chart-cartesian-percent-stacked.d.ts.map +1 -1
- package/dist/pptx/render/chart-cartesian.d.ts.map +1 -1
- package/dist/pptx/render/chart-combo-stock.cjs +3 -3
- package/dist/pptx/render/chart-combo-stock.mjs +1 -1
- package/dist/pptx/render/chart-combo.d.ts.map +1 -1
- package/dist/pptx/render/chart-gridlines-toggle.d.ts +13 -1
- package/dist/pptx/render/chart-gridlines-toggle.d.ts.map +1 -1
- package/dist/pptx/render/chart-helpers.d.ts +13 -13
- package/dist/pptx/render/chart-helpers.d.ts.map +1 -1
- package/dist/pptx/render/chart-horizontal-bars-helpers.d.ts +7 -3
- package/dist/pptx/render/chart-horizontal-bars-helpers.d.ts.map +1 -1
- package/dist/pptx/render/chart-horizontal-bars.d.ts.map +1 -1
- package/dist/pptx/render/chart-interaction-stacked.d.ts.map +1 -1
- package/dist/pptx/render/chart-overlays.cjs +7 -7
- package/dist/pptx/render/chart-overlays.mjs +1 -1
- package/dist/pptx/render/chart-palette.d.ts +5 -14
- package/dist/pptx/render/chart-palette.d.ts.map +1 -1
- package/dist/pptx/render/chart-quick-action-styles.d.ts +5 -3
- package/dist/pptx/render/chart-quick-action-styles.d.ts.map +1 -1
- package/dist/pptx/render/chart-scatter-x-axis.d.ts.map +1 -1
- package/dist/pptx/render/chart-style-palette.d.ts +52 -0
- package/dist/pptx/render/chart-style-palette.d.ts.map +1 -0
- package/dist/pptx/render/chart-surface-treemap.cjs +4 -4
- package/dist/pptx/render/chart-surface-treemap.mjs +1 -1
- package/dist/pptx/render/chart-view-model-bars.d.ts +31 -1
- package/dist/pptx/render/chart-view-model-bars.d.ts.map +1 -1
- package/dist/pptx/render/chart-view-model-build.d.ts.map +1 -1
- package/dist/pptx/render/chart-view-model.cjs +53 -41
- package/dist/pptx/render/chart-view-model.mjs +1 -1
- package/dist/pptx/render/chart-waterfall-map.cjs +6 -6
- package/dist/pptx/render/chart-waterfall-map.mjs +1 -1
- package/dist/pptx/render/foreign-object-svg-document.d.ts +12 -0
- package/dist/pptx/render/foreign-object-svg-document.d.ts.map +1 -1
- package/dist/pptx/render/index.d.ts +1 -0
- package/dist/pptx/render/index.d.ts.map +1 -1
- package/dist/pptx/render/table-cell-css.d.ts +3 -2
- package/dist/pptx/render/table-cell-css.d.ts.map +1 -1
- package/dist/pptx/render/table-cell-edit.d.ts +1 -1
- package/dist/pptx/render/table-cell-edit.d.ts.map +1 -1
- package/dist/pptx/render/table-cell-paragraphs.d.ts +29 -0
- package/dist/pptx/render/table-cell-paragraphs.d.ts.map +1 -0
- package/dist/pptx/render/table-style.d.ts +2 -0
- package/dist/pptx/render/table-style.d.ts.map +1 -1
- package/dist/pptx/render/title-bar.d.ts +5 -0
- package/dist/pptx/render/title-bar.d.ts.map +1 -1
- package/dist/pptx/render/viewer-root-options.d.ts +11 -3
- package/dist/pptx/render/viewer-root-options.d.ts.map +1 -1
- package/dist/pptx/web-components/office-token-bridge.d.ts.map +1 -1
- package/dist/presence.js +3 -3
- package/dist/ribbon/ribbon-tabs.d.ts +2 -1
- package/dist/ribbon/ribbon-tabs.d.ts.map +1 -1
- package/dist/smartart/smartart-svg.d.ts +3 -2
- package/dist/smartart.js +3 -3
- package/dist/suite/attachment-store.d.ts +13 -0
- package/dist/suite/document-store.d.ts +31 -0
- package/dist/suite/index.d.ts +2 -0
- package/dist/suite.js +132 -1
- package/dist/teams/app/channel-tab.d.ts +5 -0
- package/dist/teams/chat-composer.d.ts +3 -0
- package/dist/teams.js +6 -6
- package/dist/theme.js +2 -2
- package/dist/tokens.d.ts +5 -0
- package/dist/tokens.d.ts.map +1 -1
- package/dist/visio/styles/index.d.ts +2 -0
- package/dist/visio/styles/theme.d.ts +11 -0
- package/dist/visio/styles.d.ts +2 -2
- package/dist/visio.js +65 -20
- package/dist/xlsx/backstage/index.d.ts +4 -1
- package/dist/xlsx/backstage/pages-share.d.ts +19 -0
- package/dist/xlsx/backstage/parts.d.ts +3 -0
- package/dist/xlsx/chart-fill-binding.d.ts +2 -2
- package/dist/xlsx/chart-series-gradient-type.d.ts +3 -2
- package/dist/xlsx/collaboration-session.d.ts +9 -0
- package/dist/xlsx/collaboration-types.d.ts +41 -0
- package/dist/xlsx/collaboration.d.ts +56 -0
- package/dist/xlsx/component.d.ts +8 -0
- package/dist/xlsx/dialogs/comments-list.d.ts +4 -0
- package/dist/xlsx/dialogs/help-dialogs.d.ts +1 -1
- package/dist/xlsx/editor-core.d.ts +3 -0
- package/dist/xlsx/element-api.d.ts +19 -1
- package/dist/xlsx/events.d.ts +4 -1
- package/dist/xlsx/grid/remote-layer.d.ts +3 -0
- package/dist/xlsx/grid/sparkline.d.ts +3 -0
- package/dist/xlsx/grid/styles.d.ts +1 -1
- package/dist/xlsx/index.d.ts +1 -0
- package/dist/xlsx/ribbon-actions.d.ts +21 -0
- package/dist/xlsx/shell-commands.d.ts +1 -1
- package/dist/xlsx/title-bar.d.ts +4 -2
- package/dist/xlsx.js +712 -90
- package/package.json +2 -2
- package/dist/pptx/web-components/status-bar-styles.d.ts +0 -3
- package/dist/pptx/web-components/status-bar-styles.d.ts.map +0 -1
- package/dist/pptx/web-components/title-bar-styles.d.ts +0 -7
- package/dist/pptx/web-components/title-bar-styles.d.ts.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { DrawingFill } from 'ooxml-core/drawingml';
|
|
2
2
|
import { type OfficeUiGallery } from '../ribbon/gallery.js';
|
|
3
3
|
interface PresetOptions {
|
|
4
|
-
fill:
|
|
4
|
+
fill: DrawingFill;
|
|
5
5
|
disabled: boolean;
|
|
6
6
|
label: string;
|
|
7
7
|
translate(label: string): string;
|
package/dist/index.d.ts
CHANGED
|
@@ -8,7 +8,7 @@ export * from './teams/index.js';
|
|
|
8
8
|
export * from './theme.js';
|
|
9
9
|
export { CONTRACT_REVISION, type Definer } from './registry.js';
|
|
10
10
|
/** Every ooxml-ui tag this package defines, in registration order. */
|
|
11
|
-
export declare const OFFICE_UI_TAGS: readonly ["office-ui-icon", "office-ui-button", "office-ui-checkbox", "office-ui-switch", "office-ui-select", "office-ui-ribbon-group", "office-ui-ribbon-stack", "office-ui-menu-item", "office-ui-menu-button", "office-ui-menu-separator", "office-ui-context-menu", "office-ui-command-search", "office-ui-toolbar", "office-ui-dialog", "office-ui-status-bar", "office-ui-status-item", "office-ui-zoom-slider", "office-ui-tab-strip", "office-ui-options-dialog", "office-ui-account", "office-ui-ribbon", "office-ui-find-bar", "office-ui-ruler", "office-ui-backstage", "office-ui-print-preview", "office-ui-radio", "office-ui-search", "office-ui-ribbon-toggle", "office-ui-dialog-footer", "office-ui-toasts", "office-ui-read-only-banner", "office-ui-paste-options", "office-ui-title-bar", "office-ui-ribbon-section", "office-ui-gallery", "office-ui-presence", "office-ui-smartart", "office-ui-avatar", "office-ui-app-rail", "office-ui-channel-list", "office-ui-chat-list", "office-ui-chat-composer", "office-ui-prejoin", "office-ui-call-grid", "office-ui-call-controls"];
|
|
11
|
+
export declare const OFFICE_UI_TAGS: readonly ["office-ui-icon", "office-ui-button", "office-ui-checkbox", "office-ui-switch", "office-ui-select", "office-ui-ribbon-group", "office-ui-ribbon-stack", "office-ui-menu-item", "office-ui-menu-button", "office-ui-menu-separator", "office-ui-context-menu", "office-ui-command-search", "office-ui-toolbar", "office-ui-dialog", "office-ui-status-bar", "office-ui-status-item", "office-ui-zoom-slider", "office-ui-tab-strip", "office-ui-options-dialog", "office-ui-account", "office-ui-ribbon", "office-ui-find-bar", "office-ui-ruler", "office-ui-backstage", "office-ui-print-preview", "office-ui-radio", "office-ui-search", "office-ui-ribbon-toggle", "office-ui-dialog-footer", "office-ui-toasts", "office-ui-read-only-banner", "office-ui-paste-options", "office-ui-title-bar", "office-ui-ribbon-section", "office-ui-gallery", "office-ui-comments-pane", "office-ui-presence", "office-ui-smartart", "office-ui-avatar", "office-ui-app-rail", "office-ui-channel-list", "office-ui-chat-list", "office-ui-chat-composer", "office-ui-prejoin", "office-ui-call-grid", "office-ui-call-controls"];
|
|
12
12
|
/**
|
|
13
13
|
* Install the theme tokens and define every element. Idempotent and safe to call from every
|
|
14
14
|
* viewer binding; a no-op where there is no DOM (SSR).
|
package/dist/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
export { OFFICE_UI_TAGS, registerOfficeUi } from './chunk-
|
|
2
|
-
export { OfficeUiSmartArt, defineSmartArt, renderDiagramDrawing } from './chunk-
|
|
3
|
-
export { EMOJI, OfficeUiAppRail, OfficeUiAvatar, OfficeUiCallControls, OfficeUiCallGrid, OfficeUiChannelList, OfficeUiChatComposer, OfficeUiChatList, OfficeUiPrejoin, QUICK_REACTIONS, TEAMS_TAGS, TeamsApp, TeamsChannelTab, TeamsContentPreview, TeamsController, TeamsElement, TeamsFilesPanel, TeamsSettings, applyTeamsProps, colorFor, createTeams, dayLabel, defineAppRail, defineAvatar, defineCallControls, defineCallGrid, defineChannelList, defineChatComposer, defineChatList, definePrejoin, defineTeamsApp, defineTeamsChannelTab, defineTeamsContentPreview, defineTeamsFilesPanel, defineTeamsSettings, formatElapsed, formatSize, formatTime, icon, listenTeamsEvents, loadConfig, loadIdentity, parseIceLines, registerTeams, safeStorage, saveConfig, saveIdentity, withStyles } from './chunk-
|
|
1
|
+
export { OFFICE_UI_TAGS, registerOfficeUi } from './chunk-YP5S7DTT.js';
|
|
2
|
+
export { OfficeUiSmartArt, defineSmartArt, renderDiagramDrawing } from './chunk-Y2E22JVO.js';
|
|
3
|
+
export { EMOJI, OfficeUiAppRail, OfficeUiAvatar, OfficeUiCallControls, OfficeUiCallGrid, OfficeUiChannelList, OfficeUiChatComposer, OfficeUiChatList, OfficeUiPrejoin, QUICK_REACTIONS, TEAMS_TAGS, TeamsApp, TeamsChannelTab, TeamsContentPreview, TeamsController, TeamsElement, TeamsFilesPanel, TeamsSettings, applyTeamsProps, colorFor, createTeams, dayLabel, defineAppRail, defineAvatar, defineCallControls, defineCallGrid, defineChannelList, defineChatComposer, defineChatList, definePrejoin, defineTeamsApp, defineTeamsChannelTab, defineTeamsContentPreview, defineTeamsFilesPanel, defineTeamsSettings, formatElapsed, formatSize, formatTime, icon, listenTeamsEvents, loadConfig, loadIdentity, parseIceLines, registerTeams, safeStorage, saveConfig, saveIdentity, withStyles } from './chunk-AYXFLBSV.js';
|
|
4
4
|
export { TeamsPresentationPreview, defineTeamsPresentationPreview } from './chunk-SNV6YKPC.js';
|
|
5
|
-
export { THEME_CSS, THEME_STYLE_ID, installOfficeUiTheme, shadcnBridge, themeBridge } from './chunk-
|
|
6
|
-
export { CONTROL_DEFINERS, DEFAULT_OFFICE_PROFILE, EMPTY_MENU_STATE, OFFICE_AVATAR_SWATCHES, OFFICE_COLOR_SWATCHES, OFFICE_COLOR_SWATCH_HEXES, OFFICE_PROFILE_STORAGE_KEY, OFFICE_TITLE_BAR_SEARCH_LIMIT, OFFICE_TOAST_VISIBLE_LIMIT, assignKeyTips, attachKeyTips, clampFlyoutPosition, clampOptionNumber, clearOfficeProfile, createRibbonOverflow, defineAccount, defineBackstage, defineButton, defineCheckbox, defineCommandSearch, defineContextMenu, defineDialog, defineDialogFooter, defineFindBar, defineGallery, defineIcon, defineMenuButton, defineMenuItem, defineMenuSeparator, defineOptionsDialog, definePasteOptions, definePrintPreview, defineRadio, defineReadOnlyBanner, defineRibbon, defineRibbonGroup, defineRibbonSection, defineRibbonStack, defineRibbonToggle, defineRuler, defineSearchField, defineSelect, defineStatusBar, defineStatusItem, defineSwitch, defineTabStrip, defineTitleBar, defineToasts, defineToolbar, defineZoomSlider, glyph, nextEnabledIndex, parseSvgPreview, profileInitials, readOfficeProfile, registerControls, rulerDivisions, runKeyTips, sanitizeOfficeProfile, typeAheadIndex, writeOfficeProfile } from './chunk-
|
|
5
|
+
export { THEME_CSS, THEME_STYLE_ID, installOfficeUiTheme, shadcnBridge, themeBridge } from './chunk-JAJFLFAV.js';
|
|
6
|
+
export { CONTROL_DEFINERS, DEFAULT_COMMENTS_LABELS, DEFAULT_OFFICE_PROFILE, EMPTY_MENU_STATE, OFFICE_AVATAR_SWATCHES, OFFICE_COLOR_SWATCHES, OFFICE_COLOR_SWATCH_HEXES, OFFICE_PROFILE_STORAGE_KEY, OFFICE_TITLE_BAR_SEARCH_LIMIT, OFFICE_TOAST_VISIBLE_LIMIT, assignKeyTips, attachKeyTips, clampFlyoutPosition, clampOptionNumber, clearOfficeProfile, commentInitials, createRibbonOverflow, defineAccount, defineBackstage, defineButton, defineCheckbox, defineCommandSearch, defineCommentsPane, defineContextMenu, defineDialog, defineDialogFooter, defineFindBar, defineGallery, defineIcon, defineMenuButton, defineMenuItem, defineMenuSeparator, defineOptionsDialog, definePasteOptions, definePrintPreview, defineRadio, defineReadOnlyBanner, defineRibbon, defineRibbonGroup, defineRibbonSection, defineRibbonStack, defineRibbonToggle, defineRuler, defineSearchField, defineSelect, defineStatusBar, defineStatusItem, defineSwitch, defineTabStrip, defineTitleBar, defineToasts, defineToolbar, defineZoomSlider, formatCommentTime, glyph, nextEnabledIndex, parseSvgPreview, profileInitials, readOfficeProfile, registerControls, rulerDivisions, runKeyTips, sanitizeOfficeProfile, typeAheadIndex, writeOfficeProfile } from './chunk-7FNDOWTX.js';
|
|
7
7
|
export { createIconSvg, getIcon, listIcons, paintIcon, registerIcon } from './chunk-BOX43CZD.js';
|
|
8
|
-
export { OfficeUiPresence, definePresence, initialsOf, participantsFromAwareness } from './chunk-
|
|
9
|
-
export { CONTRACT_REVISION, OfficeElement, controlStyles, flag, readFlag, triState, valueOn, withTokens } from './chunk-
|
|
10
|
-
export { COMPACT, FOCUS_RING, OFFICE_TOKENS, TOUCH, tok } from './chunk-
|
|
8
|
+
export { OfficeUiPresence, definePresence, initialsOf, participantsFromAwareness } from './chunk-VUB44CAJ.js';
|
|
9
|
+
export { CONTRACT_REVISION, OfficeElement, controlStyles, flag, readFlag, triState, valueOn, withTokens } from './chunk-YK2DPYMU.js';
|
|
10
|
+
export { COMPACT, FOCUS_RING, OFFICE_TOKENS, TOUCH, tok } from './chunk-XNCWB2X6.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { widenPieViewModel, buildPerspCamera, createSvgEl, appendChartLegendSvg, renderChartLineSvg, renderChartTextSvg, perspBoxMatrix, pieRimPoint, perspScreenToPlaneY, resolvePieSliceShareValue, perspToScreen, roundDragValue, buildBarChart3DHoverTooltip, isChartInteractionArmed, computePieChartLayout, obliqueBarTaper } from './chunk-
|
|
2
|
-
import {
|
|
1
|
+
import { widenPieViewModel, buildPerspCamera, createSvgEl, appendChartLegendSvg, renderChartLineSvg, renderChartTextSvg, perspBoxMatrix, pieRimPoint, perspScreenToPlaneY, resolvePieSliceShareValue, perspToScreen, roundDragValue, buildBarChart3DHoverTooltip, isChartInteractionArmed, computePieChartLayout, obliqueBarTaper } from './chunk-AWKKC3VW.mjs';
|
|
2
|
+
import { resolveChartPalette, shade } from './chunk-XQVKQD5Z.mjs';
|
|
3
3
|
|
|
4
4
|
// src/pptx/render/chart-3d-shading.ts
|
|
5
5
|
var FACE_SHADE_AMOUNT = {
|
|
@@ -1193,7 +1193,7 @@ function surfaceLegend(chartData, layout, palette, background, textStyle) {
|
|
|
1193
1193
|
function mountPerspChartView(input, ctx) {
|
|
1194
1194
|
const three = ctx.three;
|
|
1195
1195
|
const { vm, layout, chartData } = input;
|
|
1196
|
-
const palette = chartData
|
|
1196
|
+
const palette = resolveChartPalette(chartData);
|
|
1197
1197
|
const camera = buildPerspCamera(three, layout.view, vm.svgWidth, vm.svgHeight);
|
|
1198
1198
|
const scene = new three.Scene();
|
|
1199
1199
|
const marks = buildPerspMarkSet(three, chartData, layout, palette);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var chunkSTKGUT5S_cjs = require('./chunk-STKGUT5S.cjs');
|
|
4
|
+
var chunkYRHK45AB_cjs = require('./chunk-YRHK45AB.cjs');
|
|
5
5
|
|
|
6
6
|
// src/pptx/render/chart-3d-shading.ts
|
|
7
7
|
var FACE_SHADE_AMOUNT = {
|
|
@@ -14,7 +14,7 @@ var FACE_SHADE_AMOUNT = {
|
|
|
14
14
|
};
|
|
15
15
|
function shadeChart3DFace(baseColor, face) {
|
|
16
16
|
const amount = FACE_SHADE_AMOUNT[face];
|
|
17
|
-
return amount === 0 ? baseColor :
|
|
17
|
+
return amount === 0 ? baseColor : chunkYRHK45AB_cjs.shade(baseColor, amount);
|
|
18
18
|
}
|
|
19
19
|
function buildChart3DBoxFaceColors(baseColor) {
|
|
20
20
|
return [
|
|
@@ -203,7 +203,7 @@ function buildChart3DBarMeshes(three, layout, svgWidth, svgHeight) {
|
|
|
203
203
|
// src/pptx/render/chart-3d-chrome-overlay.ts
|
|
204
204
|
function renderChart3DChromeOverlaySvg(doc, source, box) {
|
|
205
205
|
const vm = box ? withBoxChromePositions(source) : source;
|
|
206
|
-
const svg =
|
|
206
|
+
const svg = chunkSTKGUT5S_cjs.createSvgEl(doc, "svg", {
|
|
207
207
|
class: "pptxv-chart-3d-chrome",
|
|
208
208
|
viewBox: `0 0 ${vm.svgWidth} ${vm.svgHeight}`,
|
|
209
209
|
preserveAspectRatio: "none"
|
|
@@ -216,7 +216,7 @@ function renderChart3DChromeOverlaySvg(doc, source, box) {
|
|
|
216
216
|
svg.style.setProperty("pointer-events", "none");
|
|
217
217
|
if (vm.areaFill) {
|
|
218
218
|
svg.appendChild(
|
|
219
|
-
|
|
219
|
+
chunkSTKGUT5S_cjs.createSvgEl(doc, "rect", {
|
|
220
220
|
x: 0,
|
|
221
221
|
y: 0,
|
|
222
222
|
width: vm.svgWidth,
|
|
@@ -227,7 +227,7 @@ function renderChart3DChromeOverlaySvg(doc, source, box) {
|
|
|
227
227
|
);
|
|
228
228
|
}
|
|
229
229
|
if (vm.title) {
|
|
230
|
-
const title =
|
|
230
|
+
const title = chunkSTKGUT5S_cjs.createSvgEl(doc, "text", {
|
|
231
231
|
x: vm.titleX,
|
|
232
232
|
y: vm.titleY,
|
|
233
233
|
"text-anchor": "middle",
|
|
@@ -239,7 +239,7 @@ function renderChart3DChromeOverlaySvg(doc, source, box) {
|
|
|
239
239
|
});
|
|
240
240
|
if (vm.titleRunSpans && vm.titleRunSpans.length > 0) {
|
|
241
241
|
for (const run of vm.titleRunSpans) {
|
|
242
|
-
const tspan =
|
|
242
|
+
const tspan = chunkSTKGUT5S_cjs.createSvgEl(doc, "tspan", {
|
|
243
243
|
"font-size": run.fontSize,
|
|
244
244
|
"font-weight": run.fontWeight,
|
|
245
245
|
"font-style": run.fontStyle,
|
|
@@ -258,28 +258,28 @@ function renderChart3DChromeOverlaySvg(doc, source, box) {
|
|
|
258
258
|
appendBoxLabels(doc, svg, vm, box.labels);
|
|
259
259
|
const legend = box.legend ?? vm.legend.map((item) => ({ ...item, lineSwatch: void 0 }));
|
|
260
260
|
const legendVm = { ...vm, legend: box.reverseLegend ? legend.reverse() : legend };
|
|
261
|
-
|
|
261
|
+
chunkSTKGUT5S_cjs.appendChartLegendSvg(doc, svg, legendVm);
|
|
262
262
|
return svg;
|
|
263
263
|
}
|
|
264
264
|
for (const gl of vm.gridlines) {
|
|
265
|
-
svg.appendChild(
|
|
265
|
+
svg.appendChild(chunkSTKGUT5S_cjs.renderChartLineSvg(doc, gl));
|
|
266
266
|
}
|
|
267
267
|
for (const gl of vm.secondaryGridlines ?? []) {
|
|
268
|
-
svg.appendChild(
|
|
268
|
+
svg.appendChild(chunkSTKGUT5S_cjs.renderChartLineSvg(doc, gl));
|
|
269
269
|
}
|
|
270
270
|
for (const lbl of vm.axisLabels) {
|
|
271
|
-
svg.appendChild(
|
|
271
|
+
svg.appendChild(chunkSTKGUT5S_cjs.renderChartTextSvg(doc, lbl));
|
|
272
272
|
}
|
|
273
273
|
for (const lbl of vm.secondaryAxisLabels ?? []) {
|
|
274
|
-
svg.appendChild(
|
|
274
|
+
svg.appendChild(chunkSTKGUT5S_cjs.renderChartTextSvg(doc, lbl));
|
|
275
275
|
}
|
|
276
276
|
if (vm.zeroLine) {
|
|
277
|
-
svg.appendChild(
|
|
277
|
+
svg.appendChild(chunkSTKGUT5S_cjs.renderChartLineSvg(doc, vm.zeroLine));
|
|
278
278
|
}
|
|
279
279
|
for (const lbl of vm.categoryLabels) {
|
|
280
|
-
svg.appendChild(
|
|
280
|
+
svg.appendChild(chunkSTKGUT5S_cjs.renderChartTextSvg(doc, lbl));
|
|
281
281
|
}
|
|
282
|
-
|
|
282
|
+
chunkSTKGUT5S_cjs.appendChartLegendSvg(doc, svg, vm);
|
|
283
283
|
return svg;
|
|
284
284
|
}
|
|
285
285
|
var PT = 4 / 3;
|
|
@@ -298,7 +298,7 @@ function appendBoxLabels(doc, svg, vm, labels) {
|
|
|
298
298
|
const style = vm.axisLabels[0];
|
|
299
299
|
for (const label of labels) {
|
|
300
300
|
svg.appendChild(
|
|
301
|
-
|
|
301
|
+
chunkSTKGUT5S_cjs.renderChartTextSvg(doc, {
|
|
302
302
|
kind: "text",
|
|
303
303
|
x: label.x,
|
|
304
304
|
y: label.y,
|
|
@@ -368,7 +368,7 @@ function attachChart3DMarkInteraction(options) {
|
|
|
368
368
|
}
|
|
369
369
|
const point = pointAt(event.clientX, event.clientY);
|
|
370
370
|
const value = point ? adapter.valueOf(point) : void 0;
|
|
371
|
-
const tooltip = point && value !== void 0 ?
|
|
371
|
+
const tooltip = point && value !== void 0 ? chunkSTKGUT5S_cjs.buildBarChart3DHoverTooltip(
|
|
372
372
|
{ seriesIndex: point.seriesIndex, categoryIndex: point.pointIndex, value },
|
|
373
373
|
{
|
|
374
374
|
categoryLabels: options.categoryLabels,
|
|
@@ -386,7 +386,7 @@ function attachChart3DMarkInteraction(options) {
|
|
|
386
386
|
return;
|
|
387
387
|
}
|
|
388
388
|
const point = pointAt(event.clientX, event.clientY);
|
|
389
|
-
const armed = point !== null &&
|
|
389
|
+
const armed = point !== null && chunkSTKGUT5S_cjs.isChartInteractionArmed(target);
|
|
390
390
|
if (armed) {
|
|
391
391
|
event.stopPropagation();
|
|
392
392
|
}
|
|
@@ -462,7 +462,7 @@ function obliqueDragValue(layout, startValue, dx, dy) {
|
|
|
462
462
|
const along = layout.horizontal ? dx : -dy;
|
|
463
463
|
const raw = startValue + along / layout.valueScale;
|
|
464
464
|
const span = layout.range.max - layout.range.min;
|
|
465
|
-
return
|
|
465
|
+
return chunkSTKGUT5S_cjs.roundDragValue(raw, { min: layout.range.min, max: layout.range.max, span });
|
|
466
466
|
}
|
|
467
467
|
function obliqueDraggedExtent(layout, value) {
|
|
468
468
|
const { min, max } = layout.range;
|
|
@@ -475,7 +475,7 @@ function obliqueDraggedExtent(layout, value) {
|
|
|
475
475
|
function obliqueBarAtValue(layout, bar, value) {
|
|
476
476
|
const { from, length } = obliqueDraggedExtent(layout, value);
|
|
477
477
|
const extent = (layout.range.max - layout.range.min) * layout.valueScale;
|
|
478
|
-
const taper =
|
|
478
|
+
const taper = chunkSTKGUT5S_cjs.obliqueBarTaper(bar.shape, from, from + length, extent, value);
|
|
479
479
|
return layout.horizontal ? { ...bar, x: from, w: length, value, taper } : { ...bar, y: from, h: length, value, taper };
|
|
480
480
|
}
|
|
481
481
|
|
|
@@ -621,7 +621,7 @@ function buildPerspBarPrisms(chartData, layout, override) {
|
|
|
621
621
|
z0,
|
|
622
622
|
z1: z0 + depth,
|
|
623
623
|
shape,
|
|
624
|
-
taper:
|
|
624
|
+
taper: chunkSTKGUT5S_cjs.obliqueBarTaper(
|
|
625
625
|
shape,
|
|
626
626
|
v0,
|
|
627
627
|
v1,
|
|
@@ -816,7 +816,7 @@ function buildPerspGridlines(three, layout) {
|
|
|
816
816
|
function buildPerspMeshes(three, layout, prisms) {
|
|
817
817
|
const group = new three.Group();
|
|
818
818
|
group.matrixAutoUpdate = false;
|
|
819
|
-
group.matrix.copy(
|
|
819
|
+
group.matrix.copy(chunkSTKGUT5S_cjs.perspBoxMatrix(three, layout.view));
|
|
820
820
|
const gridlines = buildPerspGridlines(three, layout);
|
|
821
821
|
group.add(gridlines);
|
|
822
822
|
const material = new three.MeshBasicMaterial({ vertexColors: true, side: three.DoubleSide });
|
|
@@ -871,7 +871,7 @@ function surfaceBands(chartData, range, palette) {
|
|
|
871
871
|
const fmt = chartData.bandFmts?.find((b) => b.index === i)?.spPr;
|
|
872
872
|
const cycle = palette.length > 0 ? palette : ["#4472C4"];
|
|
873
873
|
const base = cycle[i % cycle.length];
|
|
874
|
-
const fallback = Math.floor(i / cycle.length) % 2 === 1 ?
|
|
874
|
+
const fallback = Math.floor(i / cycle.length) % 2 === 1 ? chunkYRHK45AB_cjs.shade(base, 0.4) : base;
|
|
875
875
|
return {
|
|
876
876
|
label: `${formatEdge(lo)}-${formatEdge(edges[i + 1])}`,
|
|
877
877
|
color: fmt?.fillColor ?? fmt?.strokeColor ?? fallback
|
|
@@ -1055,7 +1055,7 @@ function disposeObject(object) {
|
|
|
1055
1055
|
function buildSurfaceMarks(three, chartData, layout, palette) {
|
|
1056
1056
|
const group = new three.Group();
|
|
1057
1057
|
group.matrixAutoUpdate = false;
|
|
1058
|
-
group.matrix.copy(
|
|
1058
|
+
group.matrix.copy(chunkSTKGUT5S_cjs.perspBoxMatrix(three, layout.view));
|
|
1059
1059
|
const gridlines = buildPerspGridlines(three, layout);
|
|
1060
1060
|
group.add(gridlines);
|
|
1061
1061
|
let visual = buildVisual(three, chartData, layout, palette);
|
|
@@ -1195,8 +1195,8 @@ function surfaceLegend(chartData, layout, palette, background, textStyle) {
|
|
|
1195
1195
|
function mountPerspChartView(input, ctx) {
|
|
1196
1196
|
const three = ctx.three;
|
|
1197
1197
|
const { vm, layout, chartData } = input;
|
|
1198
|
-
const palette =
|
|
1199
|
-
const camera =
|
|
1198
|
+
const palette = chunkYRHK45AB_cjs.resolveChartPalette(chartData);
|
|
1199
|
+
const camera = chunkSTKGUT5S_cjs.buildPerspCamera(three, layout.view, vm.svgWidth, vm.svgHeight);
|
|
1200
1200
|
const scene = new three.Scene();
|
|
1201
1201
|
const marks = buildPerspMarkSet(three, chartData, layout, palette);
|
|
1202
1202
|
scene.add(marks.group);
|
|
@@ -1245,15 +1245,15 @@ function mountPerspChartView(input, ctx) {
|
|
|
1245
1245
|
const a = marks.anchor(point, start);
|
|
1246
1246
|
const step = unit * layout.valueScale;
|
|
1247
1247
|
const b = layout.horizontal ? [a[0] + step, a[1], a[2]] : [a[0], a[1] + step, a[2]];
|
|
1248
|
-
const s0 =
|
|
1249
|
-
const s1 =
|
|
1248
|
+
const s0 = chunkSTKGUT5S_cjs.perspToScreen(layout.view, a);
|
|
1249
|
+
const s1 = chunkSTKGUT5S_cjs.perspToScreen(layout.view, b);
|
|
1250
1250
|
const ux = (s1.x - s0.x) / unit;
|
|
1251
1251
|
const uy = (s1.y - s0.y) / unit;
|
|
1252
1252
|
const len2 = ux * ux + uy * uy || 1;
|
|
1253
1253
|
const span = layout.range.max - layout.range.min;
|
|
1254
1254
|
return {
|
|
1255
1255
|
preview(dx, dy) {
|
|
1256
|
-
const value =
|
|
1256
|
+
const value = chunkSTKGUT5S_cjs.roundDragValue(start + (dx * ux + dy * uy) / len2, {
|
|
1257
1257
|
min: layout.range.min,
|
|
1258
1258
|
max: layout.range.max,
|
|
1259
1259
|
span
|
|
@@ -1341,7 +1341,7 @@ function sliceBuffers(three, layout, slice) {
|
|
|
1341
1341
|
const steps = Math.max(2, Math.ceil(span / (Math.PI * 2) * SEGMENTS_PER_TURN));
|
|
1342
1342
|
const angles = Array.from({ length: steps + 1 }, (_, i) => slice.startAngle + span * i / steps);
|
|
1343
1343
|
const rim = (a, y) => {
|
|
1344
|
-
const p =
|
|
1344
|
+
const p = chunkSTKGUT5S_cjs.pieRimPoint(cx, cz, r, a);
|
|
1345
1345
|
return [p.x, y, p.z];
|
|
1346
1346
|
};
|
|
1347
1347
|
const radial = (a) => [Math.sin(a), 0, Math.cos(a)];
|
|
@@ -1385,7 +1385,7 @@ function sliceBuffers(three, layout, slice) {
|
|
|
1385
1385
|
function buildPieMarks(three, layout) {
|
|
1386
1386
|
const group = new three.Group();
|
|
1387
1387
|
group.matrixAutoUpdate = false;
|
|
1388
|
-
group.matrix.copy(
|
|
1388
|
+
group.matrix.copy(chunkSTKGUT5S_cjs.perspBoxMatrix(three, layout.view));
|
|
1389
1389
|
const material = new three.MeshBasicMaterial({
|
|
1390
1390
|
vertexColors: true,
|
|
1391
1391
|
side: three.DoubleSide,
|
|
@@ -1449,12 +1449,12 @@ function slicesWith(input, pointIndex, value) {
|
|
|
1449
1449
|
...input.element,
|
|
1450
1450
|
chartData: { ...input.chartData, series }
|
|
1451
1451
|
};
|
|
1452
|
-
return
|
|
1452
|
+
return chunkSTKGUT5S_cjs.computePieChartLayout(element, input.vm)?.slices ?? input.layout.slices;
|
|
1453
1453
|
}
|
|
1454
1454
|
function mountPieChartView(input, ctx) {
|
|
1455
1455
|
const three = ctx.three;
|
|
1456
1456
|
const { vm, layout, chartData } = input;
|
|
1457
|
-
const camera =
|
|
1457
|
+
const camera = chunkSTKGUT5S_cjs.buildPerspCamera(three, layout.view, vm.svgWidth, vm.svgHeight);
|
|
1458
1458
|
const scene = new three.Scene();
|
|
1459
1459
|
const marks = buildPieMarks(three, layout);
|
|
1460
1460
|
scene.add(marks.group);
|
|
@@ -1495,7 +1495,7 @@ function mountPieChartView(input, ctx) {
|
|
|
1495
1495
|
const start = values();
|
|
1496
1496
|
return {
|
|
1497
1497
|
preview(_dx, _dy, at) {
|
|
1498
|
-
const hit =
|
|
1498
|
+
const hit = chunkSTKGUT5S_cjs.perspScreenToPlaneY(layout.view, at.x, at.y, layout.center.y);
|
|
1499
1499
|
if (!hit) {
|
|
1500
1500
|
return start[point.pointIndex];
|
|
1501
1501
|
}
|
|
@@ -1503,7 +1503,7 @@ function mountPieChartView(input, ctx) {
|
|
|
1503
1503
|
hit.x - layout.center.x - slice.offset.x,
|
|
1504
1504
|
hit.z - layout.center.z - slice.offset.z
|
|
1505
1505
|
);
|
|
1506
|
-
const value =
|
|
1506
|
+
const value = chunkSTKGUT5S_cjs.resolvePieSliceShareValue(
|
|
1507
1507
|
angle,
|
|
1508
1508
|
slice.startAngle,
|
|
1509
1509
|
start,
|
|
@@ -1519,7 +1519,7 @@ function mountPieChartView(input, ctx) {
|
|
|
1519
1519
|
marker.visible = slice !== void 0;
|
|
1520
1520
|
if (slice) {
|
|
1521
1521
|
const mid = (slice.startAngle + slice.endAngle) / 2;
|
|
1522
|
-
const p =
|
|
1522
|
+
const p = chunkSTKGUT5S_cjs.pieRimPoint(
|
|
1523
1523
|
layout.center.x + slice.offset.x,
|
|
1524
1524
|
layout.center.z + slice.offset.z,
|
|
1525
1525
|
layout.radius * 0.6,
|
|
@@ -1584,7 +1584,7 @@ async function mountChart3DView(spec, ctx) {
|
|
|
1584
1584
|
return mountPieChartView(
|
|
1585
1585
|
{
|
|
1586
1586
|
element: spec.element,
|
|
1587
|
-
vm:
|
|
1587
|
+
vm: chunkSTKGUT5S_cjs.widenPieViewModel(spec.vm, spec.element),
|
|
1588
1588
|
layout: spec.geometry.layout,
|
|
1589
1589
|
chartData: chartData2,
|
|
1590
1590
|
categoryLabels: spec.categoryLabels
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { chartTextFontFamily, chartFontPx, computePlotLayout, radarAngle, computeStackedSeriesPlots, computeLayoutOptions,
|
|
1
|
+
import { chartTextFontFamily, chartFontPx, computePlotLayout, radarAngle, computeStackedSeriesPlots, computeLayoutOptions, computeStackedValueRangeForAxis, primaryValueAxis, valueToY2, collapseChartTitleRunsForEdit, computePieLayout, buildMarkTooltip, formatAxisValueWithUnits, axisTickValues } from './chunk-XQVKQD5Z.mjs';
|
|
2
2
|
|
|
3
3
|
// src/pptx/render/chart-legend-layout.ts
|
|
4
4
|
var LEGEND_ITEM_WIDTH = 80;
|
|
@@ -60,7 +60,13 @@ function buildStackedDragGeometry(element, chartData, seriesIndex, pointIndex) {
|
|
|
60
60
|
), plots = computeStackedSeriesPlots(seriesValues, catCount, percent), baseValue = plots[seriesIndex]?.base[pointIndex] ?? 0, otherAbsSum = seriesValues.reduce(
|
|
61
61
|
(sum, values, si) => si === seriesIndex ? sum : sum + Math.abs(values[pointIndex] ?? 0),
|
|
62
62
|
0
|
|
63
|
-
), layoutOpts = computeLayoutOptions(chartData.axes, chartData.dataTable, chartData.series.length), layout = computePlotLayout(element.width, element.height, chartData, true, layoutOpts), range =
|
|
63
|
+
), layoutOpts = computeLayoutOptions(chartData.axes, chartData.dataTable, chartData.series.length), layout = computePlotLayout(element.width, element.height, chartData, true, layoutOpts), range = computeStackedValueRangeForAxis(
|
|
64
|
+
chartData.series,
|
|
65
|
+
catCount,
|
|
66
|
+
primaryValueAxis(chartData.axes),
|
|
67
|
+
percent,
|
|
68
|
+
layout.autoPlotHeight
|
|
69
|
+
);
|
|
64
70
|
return {
|
|
65
71
|
range,
|
|
66
72
|
plotTop: layout.plotTop,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkYRHK45AB_cjs = require('./chunk-YRHK45AB.cjs');
|
|
4
4
|
|
|
5
5
|
// src/pptx/render/chart-legend-layout.ts
|
|
6
6
|
var LEGEND_ITEM_WIDTH = 80;
|
|
@@ -16,11 +16,11 @@ function computeChartLegendLayout(vm) {
|
|
|
16
16
|
y,
|
|
17
17
|
color: entry.color,
|
|
18
18
|
label: entry.label,
|
|
19
|
-
fontSize: textStyle?.fontSize !== void 0 ?
|
|
19
|
+
fontSize: textStyle?.fontSize !== void 0 ? chunkYRHK45AB_cjs.chartFontPx(textStyle.fontSize) : DEFAULT_LEGEND_FONT_SIZE,
|
|
20
20
|
fill: textStyle?.color ?? DEFAULT_LEGEND_TEXT_COLOR,
|
|
21
21
|
fontWeight: textStyle?.bold ? "bold" : "normal",
|
|
22
22
|
fontStyle: textStyle?.italic ? "italic" : "normal",
|
|
23
|
-
fontFamily:
|
|
23
|
+
fontFamily: chunkYRHK45AB_cjs.chartTextFontFamily(textStyle),
|
|
24
24
|
...entry.lineSwatch ? { lineSwatch: entry.lineSwatch } : {}
|
|
25
25
|
};
|
|
26
26
|
});
|
|
@@ -35,7 +35,7 @@ function buildRadarDragGeometry(element, chartData, categoryLabels, pointIndex)
|
|
|
35
35
|
if (pointIndex < 0 || pointIndex >= catCount) {
|
|
36
36
|
return null;
|
|
37
37
|
}
|
|
38
|
-
const layout =
|
|
38
|
+
const layout = chunkYRHK45AB_cjs.computePlotLayout(element.width, element.height, chartData, false), cx = layout.plotLeft + layout.plotWidth / 2, cy = layout.plotTop + layout.plotHeight / 2, radius = Math.max(Math.min(layout.plotWidth, layout.plotHeight) / 2 - 4, 1), maxVal = Math.max(1, ...chartData.series.flatMap((s) => s.values.map((v) => Math.abs(v)))), angle = chunkYRHK45AB_cjs.radarAngle(pointIndex, catCount);
|
|
39
39
|
return { cx, cy, radius, maxVal, angle };
|
|
40
40
|
}
|
|
41
41
|
function resolveRadarDragValue(geometry, pointerX, pointerY) {
|
|
@@ -59,10 +59,16 @@ function buildStackedDragGeometry(element, chartData, seriesIndex, pointIndex) {
|
|
|
59
59
|
chartData.categories.length,
|
|
60
60
|
...seriesValues.map((values) => values.length),
|
|
61
61
|
pointIndex + 1
|
|
62
|
-
), plots =
|
|
62
|
+
), plots = chunkYRHK45AB_cjs.computeStackedSeriesPlots(seriesValues, catCount, percent), baseValue = plots[seriesIndex]?.base[pointIndex] ?? 0, otherAbsSum = seriesValues.reduce(
|
|
63
63
|
(sum, values, si) => si === seriesIndex ? sum : sum + Math.abs(values[pointIndex] ?? 0),
|
|
64
64
|
0
|
|
65
|
-
), layoutOpts =
|
|
65
|
+
), layoutOpts = chunkYRHK45AB_cjs.computeLayoutOptions(chartData.axes, chartData.dataTable, chartData.series.length), layout = chunkYRHK45AB_cjs.computePlotLayout(element.width, element.height, chartData, true, layoutOpts), range = chunkYRHK45AB_cjs.computeStackedValueRangeForAxis(
|
|
66
|
+
chartData.series,
|
|
67
|
+
catCount,
|
|
68
|
+
chunkYRHK45AB_cjs.primaryValueAxis(chartData.axes),
|
|
69
|
+
percent,
|
|
70
|
+
layout.autoPlotHeight
|
|
71
|
+
);
|
|
66
72
|
return {
|
|
67
73
|
range,
|
|
68
74
|
plotTop: layout.plotTop,
|
|
@@ -174,7 +180,7 @@ function dragValueForPart(viewY, drag, seriesIndex) {
|
|
|
174
180
|
return roundDragValue(valueFromY(viewY, range, drag.plotTop, drag.plotBottom), range);
|
|
175
181
|
}
|
|
176
182
|
function dragAnchorViewY(value, drag, seriesIndex) {
|
|
177
|
-
return
|
|
183
|
+
return chunkYRHK45AB_cjs.valueToY2(value, rangeForSeries(drag, seriesIndex), drag.plotTop, drag.plotBottom);
|
|
178
184
|
}
|
|
179
185
|
function withChartPointValue(chartData, seriesIndex, pointIndex, value) {
|
|
180
186
|
const series = chartData.series[seriesIndex];
|
|
@@ -195,7 +201,7 @@ function withChartTitle(chartData, title) {
|
|
|
195
201
|
// A multi-run title collapses to one run in its dominant style so this
|
|
196
202
|
// edit does not leave another, now-stale run's text trailing the new
|
|
197
203
|
// title; see `collapseChartTitleRunsForEdit`'s doc.
|
|
198
|
-
...
|
|
204
|
+
...chunkYRHK45AB_cjs.collapseChartTitleRunsForEdit(chartData, trimmed),
|
|
199
205
|
style: { ...chartData.style, hasTitle: trimmed.length > 0 }
|
|
200
206
|
};
|
|
201
207
|
}
|
|
@@ -241,7 +247,7 @@ function buildPieDragGeometry(element, chartData, pointIndex) {
|
|
|
241
247
|
if (!series || pointIndex < 0 || pointIndex >= series.values.length) {
|
|
242
248
|
return null;
|
|
243
249
|
}
|
|
244
|
-
const isDoughnut = chartData.chartType === "doughnut", { cx, cy } =
|
|
250
|
+
const isDoughnut = chartData.chartType === "doughnut", { cx, cy } = chunkYRHK45AB_cjs.computePieLayout(element.width, element.height, chartData, isDoughnut), startAngle = -Math.PI / 2 + (chartData.firstSliceAngle ?? 0) * Math.PI / 180;
|
|
245
251
|
return { cx, cy, values: series.values, pointIndex, startAngle };
|
|
246
252
|
}
|
|
247
253
|
function resolvePieSliceShareValue(pointerAngle, leadingAngle, values, pointIndex) {
|
|
@@ -955,7 +961,7 @@ function buildBarChart3DHoverTooltip(hit, data) {
|
|
|
955
961
|
if (!hit) {
|
|
956
962
|
return void 0;
|
|
957
963
|
}
|
|
958
|
-
return
|
|
964
|
+
return chunkYRHK45AB_cjs.buildMarkTooltip(
|
|
959
965
|
data.seriesNames[hit.seriesIndex],
|
|
960
966
|
data.categoryLabels[hit.categoryIndex],
|
|
961
967
|
hit.value,
|
|
@@ -968,7 +974,7 @@ function formatValueLabel(chartData, grouping, v) {
|
|
|
968
974
|
if (grouping === "percentStacked") {
|
|
969
975
|
return `${Math.round(v * 100)}%`;
|
|
970
976
|
}
|
|
971
|
-
return
|
|
977
|
+
return chunkYRHK45AB_cjs.formatAxisValueWithUnits(
|
|
972
978
|
v,
|
|
973
979
|
chartData.axes?.find((a) => a.axisType === "valAx")
|
|
974
980
|
);
|
|
@@ -1052,7 +1058,7 @@ function buildGridlines(layout) {
|
|
|
1052
1058
|
const { w, h, d } = layout.box;
|
|
1053
1059
|
const lines = [];
|
|
1054
1060
|
const span = layout.range.max - layout.range.min;
|
|
1055
|
-
for (const v of
|
|
1061
|
+
for (const v of chunkYRHK45AB_cjs.axisTickValues({ ...layout.range, span })) {
|
|
1056
1062
|
const p = valuePos(layout, v);
|
|
1057
1063
|
if (layout.horizontal) {
|
|
1058
1064
|
lines.push({ from: [p, 0, d], to: [p, h, d] }, { from: [p, 0, 0], to: [p, 0, d] });
|
|
@@ -32,7 +32,7 @@ async function loadChart3DThree() {
|
|
|
32
32
|
|
|
33
33
|
// src/pptx/three-view/scene-registry.ts
|
|
34
34
|
var loaders = {
|
|
35
|
-
chart: async () => (await import('./chart-3d-view-scene-
|
|
35
|
+
chart: async () => (await import('./chart-3d-view-scene-MJ6YNT56.cjs')).mountChart3DView,
|
|
36
36
|
smartart: async () => (await import('./view-scene-4ZFUCP6S.cjs')).mountSmartArt3DView
|
|
37
37
|
};
|
|
38
38
|
async function loadThreeViewScene(kind) {
|