@formicoidea/labre-framework-wardley 0.53.0 → 0.55.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.
@@ -0,0 +1,12 @@
1
+ import type { NotationDarkPalette } from '@formicoidea/labre-core/blocks/surface';
2
+ /**
3
+ * Wardley on a dark canvas (ADR 0039). The neutrals come from the shared
4
+ * scale; these are the map's own values that would vanish on the dark card.
5
+ *
6
+ * - The four evolution bands step DARKER than the card, as they step darker
7
+ * than white in light: the gradient keeps its direction, and the dark
8
+ * selection accent keeps 3:1 on every band (`notation-dark-palettes`).
9
+ * - The greys a node or a link is painted in keep the contrast they have on
10
+ * white, on the other side of the card.
11
+ */
12
+ export declare const WARDLEY_DARK_PALETTE: NotationDarkPalette;
@@ -0,0 +1,27 @@
1
+ import { COLORS } from './consts.js';
2
+ import { PORTER_PANEL } from './legend.js';
3
+ import { ACCELERATOR_FILL, LINK_GREY, METHOD_FILL } from './node/consts.js';
4
+ /**
5
+ * Wardley on a dark canvas (ADR 0039). The neutrals come from the shared
6
+ * scale; these are the map's own values that would vanish on the dark card.
7
+ *
8
+ * - The four evolution bands step DARKER than the card, as they step darker
9
+ * than white in light: the gradient keeps its direction, and the dark
10
+ * selection accent keeps 3:1 on every band (`notation-dark-palettes`).
11
+ * - The greys a node or a link is painted in keep the contrast they have on
12
+ * white, on the other side of the card.
13
+ */
14
+ export const WARDLEY_DARK_PALETTE = {
15
+ framework: 'wardley',
16
+ colors: {
17
+ [COLORS.band[0]]: '#101317',
18
+ [COLORS.band[1]]: '#0b1016',
19
+ [COLORS.band[2]]: '#060d16',
20
+ [COLORS.band[3]]: '#020a16',
21
+ [LINK_GREY]: '#909090',
22
+ [METHOD_FILL]: '#313131',
23
+ [ACCELERATOR_FILL]: '#434343',
24
+ [PORTER_PANEL.backing]: '#26282b',
25
+ },
26
+ kept: [],
27
+ };
package/dist/legend.d.ts CHANGED
@@ -88,6 +88,30 @@ export declare const WARDLEY_LEGEND_DESC_WORDINGS: readonly ChromeWording[];
88
88
  export declare function wardleyLegendEntry(role: WardleyLegendRole): CommandLegendEntry;
89
89
  /** Every {@link LEGEND_GRADIENT} caption, for `translations.ts`'s manifest. */
90
90
  export declare const WARDLEY_LEGEND_GRADIENT_WORDINGS: readonly ChromeWording[];
91
+ /** The panel's own numbers. Model units, like every other measure here. */
92
+ export declare const PORTER_PANEL: {
93
+ readonly pad: 12;
94
+ readonly titleFs: 16;
95
+ readonly titleH: 22;
96
+ /** Between the title and the diagram, and between the diagram and caption. */
97
+ readonly gapAfterTitle: 8;
98
+ readonly gapBeforeCaption: 10;
99
+ /** The glyph's radius — half the map's, so the panel reads as a diagram. */
100
+ readonly radius: 15;
101
+ /** Clearance between the arrow tips and the boxes they point at. */
102
+ readonly clearance: 4;
103
+ /** The three letters, drawn on the glyph's centre as a free text. */
104
+ readonly letterFs: 9;
105
+ readonly boxFs: 12;
106
+ readonly sideW: 150;
107
+ readonly sideH: 34;
108
+ readonly endW: 170;
109
+ readonly endH: 24;
110
+ readonly captionFs: 13;
111
+ readonly captionH: 21;
112
+ readonly backing: "#e5e7eb";
113
+ readonly backingStroke: string;
114
+ };
91
115
  /** The five-forces panel's own title. */
92
116
  export declare const WARDLEY_LEGEND_PORTER_TITLE: ChromeWording;
93
117
  /** Every {@link PORTER_FORCES} wording, plus the caption, for the manifest. */
package/dist/legend.js CHANGED
@@ -408,7 +408,7 @@ function gradientExtra(variant) {
408
408
  }
409
409
  /* ── Extra 2: Porter's five forces ────────────────────────────────────── */
410
410
  /** The panel's own numbers. Model units, like every other measure here. */
411
- const PORTER_PANEL = {
411
+ export const PORTER_PANEL = {
412
412
  pad: 12,
413
413
  titleFs: 16,
414
414
  titleH: 22,
@@ -1,4 +1,4 @@
1
- import { ElementRendererExtension, } from '@formicoidea/labre-core/blocks/surface';
1
+ import { ElementRendererExtension, notationColor, } from '@formicoidea/labre-core/blocks/surface';
2
2
  import { shape as shapeRenderer } from '@formicoidea/labre-core/gfx/shape';
3
3
  import { DefaultTheme, } from '@formicoidea/labre-core/model';
4
4
  import { ANCHOR, ECOSYSTEM, METHOD, NODE_FILL } from './consts.js';
@@ -72,7 +72,7 @@ export const wardleyNode = (model, ctx, matrix, renderer, rc, bound) => {
72
72
  // ── Method: a white component inscribed in the colored outer circle ──
73
73
  if (model.kind === 'method') {
74
74
  const rInner = R * METHOD.centerRatio;
75
- ctx.fillStyle = NODE_FILL;
75
+ ctx.fillStyle = notationColor(renderer, NODE_FILL, 'fill');
76
76
  ctx.lineWidth = strokeWidth;
77
77
  ctx.strokeStyle = color;
78
78
  ctx.beginPath();
package/dist/view.js CHANGED
@@ -1,4 +1,4 @@
1
- import { InterchangeExtension, morphToolbarConfig, ReadingProfileExtension, tagsToolbarConfig, QualityNudgeExtension, ValidationProfileExtension, ValidationRuleExtension, } from '@formicoidea/labre-core/blocks/surface';
1
+ import { InterchangeExtension, morphToolbarConfig, ReadingProfileExtension, tagsToolbarConfig, QualityNudgeExtension, ValidationProfileExtension, ValidationRuleExtension, NotationDarkPaletteExtension, } from '@formicoidea/labre-core/blocks/surface';
2
2
  import { AuditCriterionExtension, ToolbarModuleExtension, toolbarModuleKey, UniverseTagDefsExtension, } from '@formicoidea/labre-core/shared/services';
3
3
  import { FrameworkPaletteExtension } from '@formicoidea/labre-core/components/color-picker';
4
4
  import { ViewExtensionProvider, } from '@formicoidea/labre-core/ext-loader';
@@ -25,6 +25,7 @@ import { WardleyPorterWatcher } from './node/porter-watcher.js';
25
25
  import { WARDLEY_FRAMEWORK_PALETTE, wardleyNodeToolbarExtension, } from './toolbar/node-config.js';
26
26
  import { wardleyBoardToolingToolbarExtension, wardleyToolbarExtension, } from './toolbar/config.js';
27
27
  import { wardleySeniorTool } from './toolbar/senior-tool.js';
28
+ import { WARDLEY_DARK_PALETTE } from './dark-palette.js';
28
29
  /**
29
30
  * Wardley rendering — ALWAYS registered, independent of any flag. Disabling
30
31
  * `wardley` hides only the creation tooling (see {@link WardleyViewExtension});
@@ -38,6 +39,7 @@ export class WardleyRenderViewExtension extends ViewExtensionProvider {
38
39
  }
39
40
  setup(context) {
40
41
  super.setup(context);
42
+ context.register(NotationDarkPaletteExtension(WARDLEY_DARK_PALETTE));
41
43
  context.register(WardleyView);
42
44
  context.register(WardleyElementRendererExtension);
43
45
  context.register(WardleyNodeView);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@formicoidea/labre-framework-wardley",
3
3
  "description": "Labre wardley framework for @formicoidea/labre-core.",
4
- "version": "0.53.0",
4
+ "version": "0.55.0",
5
5
  "type": "module",
6
6
  "sideEffects": false,
7
7
  "author": "lajola",
@@ -35,7 +35,7 @@
35
35
  "dist"
36
36
  ],
37
37
  "dependencies": {
38
- "@formicoidea/labre-core": "0.53.0",
38
+ "@formicoidea/labre-core": "0.55.0",
39
39
  "lit": "^3.2.0"
40
40
  }
41
41
  }