@examind/block-editor 0.1.15 → 0.1.17

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/index.js CHANGED
@@ -31,6 +31,7 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
31
31
  var index_exports = {};
32
32
  __export(index_exports, {
33
33
  BlockEditor: () => BlockEditor,
34
+ BlockEditorStyle: () => BlockEditorStyle,
34
35
  Callout: () => Callout,
35
36
  Debug: () => Debug,
36
37
  Image: () => Image,
@@ -4394,16 +4395,22 @@ function humanReadableBytes(bytes) {
4394
4395
  return `${Math.round(bytes / Math.pow(1024, i))} ${sizes[i]}`;
4395
4396
  }
4396
4397
  }
4397
- function getNumber(str) {
4398
- const trimmedStr = str.trim();
4399
- if (trimmedStr === "") {
4400
- return void 0;
4398
+ function getNumber(value) {
4399
+ if (typeof value === "number") {
4400
+ return Number.isNaN(value) ? void 0 : value;
4401
4401
  }
4402
- const num = +trimmedStr;
4403
- if (Number.isNaN(num)) {
4404
- return void 0;
4402
+ if (typeof value === "string") {
4403
+ const trimmedStr = value.trim();
4404
+ if (trimmedStr === "") {
4405
+ return void 0;
4406
+ }
4407
+ const num = +trimmedStr;
4408
+ return Number.isNaN(num) ? void 0 : num;
4409
+ }
4410
+ if (typeof value === "boolean") {
4411
+ return value ? 1 : 0;
4405
4412
  }
4406
- return num;
4413
+ return void 0;
4407
4414
  }
4408
4415
  var formatNumber = (num, format) => {
4409
4416
  return format ? (0, import_numeral.default)(num).format(format) : autoFormatNumber(num);
@@ -5393,14 +5400,18 @@ var VariableNode = class _VariableNode extends import_lexical23.DecoratorNode {
5393
5400
  this.__variable
5394
5401
  );
5395
5402
  if (this.__isPreviewMode) {
5396
- const variableAsNumber = this.__variableValue ? getNumber(this.__variableValue) : void 0;
5397
- if (variableAsNumber) {
5398
- element.textContent = formatNumber(
5399
- variableAsNumber,
5400
- this.__variableFormat
5401
- );
5403
+ if (this.__variableFormat) {
5404
+ const variableAsNumber = this.__variableValue ? getNumber(this.__variableValue) : void 0;
5405
+ if (variableAsNumber) {
5406
+ element.textContent = formatNumber(
5407
+ variableAsNumber,
5408
+ this.__variableFormat
5409
+ );
5410
+ } else {
5411
+ element.textContent = "[???]";
5412
+ }
5402
5413
  } else {
5403
- element.textContent = "[???]";
5414
+ element.textContent = this.__variableValue || "[???]";
5404
5415
  }
5405
5416
  } else {
5406
5417
  element.textContent = this.__variable;
@@ -5418,14 +5429,18 @@ var VariableNode = class _VariableNode extends import_lexical23.DecoratorNode {
5418
5429
  }
5419
5430
  updateDOM(_prevNode, dom, _config) {
5420
5431
  if (this.__isPreviewMode) {
5421
- const variableAsNumber = this.__variableValue ? getNumber(this.__variableValue) : void 0;
5422
- if (variableAsNumber) {
5423
- dom.textContent = formatNumber(
5424
- variableAsNumber,
5425
- this.__variableFormat
5426
- );
5432
+ if (this.__variableFormat) {
5433
+ const variableAsNumber = this.__variableValue ? getNumber(this.__variableValue) : void 0;
5434
+ if (variableAsNumber) {
5435
+ dom.textContent = formatNumber(
5436
+ variableAsNumber,
5437
+ this.__variableFormat
5438
+ );
5439
+ } else {
5440
+ dom.textContent = "[???]";
5441
+ }
5427
5442
  } else {
5428
- dom.textContent = "[???]";
5443
+ dom.textContent = this.__variableValue || "[???]";
5429
5444
  }
5430
5445
  } else {
5431
5446
  dom.textContent = this.__variable;
@@ -17159,23 +17174,705 @@ function TypeaheadMenuPlugin() {
17159
17174
  );
17160
17175
  }
17161
17176
 
17177
+ // src/theme/defaultThemeVariables.ts
17178
+ var themeLight = `
17179
+ :host,
17180
+ .theme-light {
17181
+ color-scheme: light;
17182
+
17183
+ --sl-color-primary-50: #f0f9ff;
17184
+ --sl-color-primary-100: #e0f2fe;
17185
+ --sl-color-primary-200: #bae6fd;
17186
+ --sl-color-primary-300: #93c5fd;
17187
+ --sl-color-primary-400: #60a5fa;
17188
+ --sl-color-primary-500: #3b82f6;
17189
+ --sl-color-primary-600: #2563eb;
17190
+ --sl-color-primary-700: #1d4ed8;
17191
+ --sl-color-primary-800: #1e40af;
17192
+ --sl-color-primary-900: #1e3a8a;
17193
+ --sl-color-primary-950: #172554;
17194
+
17195
+ --sl-color-success-50: #f0fdf4;
17196
+ --sl-color-success-100: #dcfce7;
17197
+ --sl-color-success-200: #bbf7d0;
17198
+ --sl-color-success-300: #86efac;
17199
+ --sl-color-success-400: #4ade80;
17200
+ --sl-color-success-500: #22c55e;
17201
+ --sl-color-success-600: #16a34a;
17202
+ --sl-color-success-700: #15803d;
17203
+ --sl-color-success-800: #166534;
17204
+ --sl-color-success-900: #14532d;
17205
+ --sl-color-success-950: #052e16;
17206
+
17207
+ --sl-color-warning-50: #fffbeb;
17208
+ --sl-color-warning-100: #fef3c7;
17209
+ --sl-color-warning-200: #fde68a;
17210
+ --sl-color-warning-300: #fcd34d;
17211
+ --sl-color-warning-400: #fbbf24;
17212
+ --sl-color-warning-500: #f59e0b;
17213
+ --sl-color-warning-600: #d97706;
17214
+ --sl-color-warning-700: #b45309;
17215
+ --sl-color-warning-800: #92400e;
17216
+ --sl-color-warning-900: #78350f;
17217
+ --sl-color-warning-950: #451a03;
17218
+
17219
+ --sl-color-danger-50: #fef2f2;
17220
+ --sl-color-danger-100: #fee2e2;
17221
+ --sl-color-danger-200: #fecaca;
17222
+ --sl-color-danger-300: #fca5a5;
17223
+ --sl-color-danger-400: #f87171;
17224
+ --sl-color-danger-500: #ef4444;
17225
+ --sl-color-danger-600: #dc2626;
17226
+ --sl-color-danger-700: #b91c1c;
17227
+ --sl-color-danger-800: #991b1b;
17228
+ --sl-color-danger-900: #7f1d1d;
17229
+ --sl-color-danger-950: #450a0a;
17230
+
17231
+ --sl-color-neutral-50: #fafafa;
17232
+ --sl-color-neutral-100: #f4f4f5;
17233
+ --sl-color-neutral-200: #e4e4e7;
17234
+ --sl-color-neutral-300: #d4d4d8;
17235
+ --sl-color-neutral-400: #a1a1aa;
17236
+ --sl-color-neutral-500: #71717a;
17237
+ --sl-color-neutral-600: #52525b;
17238
+ --sl-color-neutral-700: #3f3f46;
17239
+ --sl-color-neutral-800: #27272a;
17240
+ --sl-color-neutral-900: #18181b;
17241
+ --sl-color-neutral-950: #09090b;
17242
+
17243
+ --sl-color-neutral-0: #ffffff;
17244
+ --sl-color-neutral-1000: hsl(0, 0%, 0%);
17245
+
17246
+ --sl-border-base: var(--be-border-base);
17247
+ --sl-border-radius-small: calc(var(--sl-border-base) * 0.1875);
17248
+ --sl-border-radius-medium: calc(var(--sl-border-base) * 0.25);
17249
+ --sl-border-radius-large: calc(var(--sl-border-base) * 0.5);
17250
+ --sl-border-radius-x-large: var(
17251
+ --sl-border-base
17252
+ );
17253
+
17254
+ --sl-border-radius-circle: 50%;
17255
+ --sl-border-radius-pill: 9999px;
17256
+
17257
+ --sl-shadow-x-small: 0 1px 2px hsl(240 3.8% 46.1% / 6%);
17258
+ --sl-shadow-small: 0 1px 2px hsl(240 3.8% 46.1% / 12%);
17259
+ --sl-shadow-medium: 0 2px 4px hsl(240 3.8% 46.1% / 12%);
17260
+ --sl-shadow-large: var(
17261
+ --be-shadow-large,
17262
+ 0 2px 8px hsl(240 3.8% 46.1% / 12%)
17263
+ );
17264
+ --sl-shadow-x-large: 0 4px 16px hsl(240 3.8% 46.1% / 12%);
17265
+
17266
+ --sl-spacing-base: var(--be-spacing-base, 1rem);
17267
+ --sl-spacing-3x-small: calc(
17268
+ var(--sl-spacing-base) * 0.125
17269
+ );
17270
+ --sl-spacing-2x-small: calc(
17271
+ var(--sl-spacing-base) * 0.25
17272
+ );
17273
+ --sl-spacing-1_5x-small: calc(
17274
+ var(--sl-spacing-base) * 0.375
17275
+ );
17276
+ --sl-spacing-x-small: calc(
17277
+ var(--sl-spacing-base) * 0.5
17278
+ );
17279
+ --sl-spacing-small: calc(
17280
+ var(--sl-spacing-base) * 0.75
17281
+ );
17282
+ --sl-spacing-medium: var(--sl-spacing-base);
17283
+ --sl-spacing-large: calc(
17284
+ var(--sl-spacing-base) * 1.25
17285
+ );
17286
+ --sl-spacing-x-large: calc(
17287
+ var(--sl-spacing-base) * 1.75
17288
+ );
17289
+ --sl-spacing-2x-large: calc(
17290
+ var(--sl-spacing-base) * 2.25
17291
+ );
17292
+ --sl-spacing-3x-large: calc(
17293
+ var(--sl-spacing-base) * 3
17294
+ );
17295
+ --sl-spacing-4x-large: calc(
17296
+ var(--sl-spacing-base) * 4.5
17297
+ );
17298
+ --sl-spacing-5x-large: calc(var(--sl-spacing-base) * 5);
17299
+
17300
+ --indent-size: var(--sl-spacing-large);
17301
+
17302
+ --sl-transition-x-slow: 1000ms;
17303
+ --sl-transition-slow: 500ms;
17304
+ --sl-transition-medium: 250ms;
17305
+ --sl-transition-fast: 150ms;
17306
+ --sl-transition-x-fast: 50ms;
17307
+
17308
+ --sl-font-mono: SFMono-Regular, Consolas, 'Liberation Mono', Menlo,
17309
+ monospace;
17310
+ --sl-font-sans: var(
17311
+ --be-font-sans,
17312
+ -apple-system,
17313
+ BlinkMacSystemFont,
17314
+ 'Segoe UI',
17315
+ Roboto,
17316
+ Helvetica,
17317
+ Arial,
17318
+ sans-serif,
17319
+ 'Apple Color Emoji',
17320
+ 'Segoe UI Emoji',
17321
+ 'Segoe UI Symbol'
17322
+ );
17323
+ --sl-font-serif: var(
17324
+ --be-font-serif,
17325
+ Georgia,
17326
+ 'Times New Roman',
17327
+ serif
17328
+ );
17329
+
17330
+ --sl-font-size-base: var(--be-font-size-base, 1rem);
17331
+ --sl-font-size-2x-small: calc(var(--sl-font-size-base) * 0.625);
17332
+ --sl-font-size-x-small: calc(var(--sl-font-size-base) * 0.75);
17333
+ --sl-font-size-small: calc(var(--sl-font-size-base) * 0.875);
17334
+ --sl-font-size-medium: var(--sl-font-size-base);
17335
+ --sl-font-size-large: calc(var(--sl-font-size-base) * 1.25);
17336
+ --sl-font-size-x-large: calc(var(--sl-font-size-base) * 1.5);
17337
+ --sl-font-size-2x-large: calc(var(--sl-font-size-base) * 2.25);
17338
+ --sl-font-size-3x-large: calc(var(--sl-font-size-base) * 3);
17339
+ --sl-font-size-4x-large: calc(var(--sl-font-size-base) * 4.5);
17340
+
17341
+ --sl-font-weight-light: 300;
17342
+ --sl-font-weight-normal: 400;
17343
+ --sl-font-weight-semibold: 500;
17344
+ --sl-font-weight-bold: 700;
17345
+
17346
+ --sl-letter-spacing-denser: -0.03em;
17347
+ --sl-letter-spacing-dense: -0.015em;
17348
+ --sl-letter-spacing-normal: normal;
17349
+ --sl-letter-spacing-loose: 0.075em;
17350
+ --sl-letter-spacing-looser: 0.15em;
17351
+
17352
+ --sl-line-height-base: 1;
17353
+ --sl-line-height-x-denser: calc(var(--sl-line-height-base) * 1.1);
17354
+ --sl-line-height-denser: calc(var(--sl-line-height-base) * 1.2);
17355
+ --sl-line-height-dense: calc(var(--sl-line-height-base) * 1.4);
17356
+ --sl-line-height-subnormal: calc(var(--sl-line-height-base) * 1.6);
17357
+ --sl-line-height-normal: calc(var(--sl-line-height-base) * 1.8);
17358
+ --sl-line-height-loose: calc(var(--sl-line-height-base) * 2.2);
17359
+ --sl-line-height-looser: calc(var(--sl-line-height-base) * 2.6);
17360
+
17361
+ --sl-focus-ring-color: var(--sl-color-primary-600);
17362
+ --sl-focus-ring-style: solid;
17363
+ --sl-focus-ring-width: var(--be-focus-ring-width, 1px);
17364
+ --sl-focus-ring: var(--sl-focus-ring-style)
17365
+ var(--sl-focus-ring-width) var(--sl-focus-ring-color);
17366
+ --sl-focus-ring-offset: 1px;
17367
+
17368
+ --sl-button-font-size-small: var(--sl-font-size-x-small);
17369
+ --sl-button-font-size-medium: var(--sl-font-size-small);
17370
+ --sl-button-font-size-large: var(--sl-font-size-medium);
17371
+
17372
+ --sl-input-height-base: 1rem;
17373
+ --sl-input-height-small: calc(var(--sl-input-height-base) * 1.875);
17374
+ --sl-input-height-medium: calc(var(--sl-input-height-base) * 2.5);
17375
+ --sl-input-height-large: calc(var(--sl-input-height-base) * 3.125);
17376
+
17377
+ --sl-input-background-color: var(--sl-color-neutral-0);
17378
+ --sl-input-background-color-hover: var(--sl-input-background-color);
17379
+ --sl-input-background-color-focus: var(--sl-input-background-color);
17380
+ --sl-input-background-color-disabled: var(--sl-color-neutral-100);
17381
+ --sl-input-border-color: var(--sl-color-neutral-300);
17382
+ --sl-input-border-color-hover: var(--sl-color-neutral-400);
17383
+ --sl-input-border-color-focus: var(--sl-color-primary-500);
17384
+ --sl-input-border-color-disabled: var(--sl-color-neutral-300);
17385
+ --sl-input-border-width: 1px;
17386
+ --sl-input-required-content: '*';
17387
+ --sl-input-required-content-offset: -2px;
17388
+ --sl-input-required-content-color: var(--sl-input-label-color);
17389
+
17390
+ --sl-input-border-radius-small: var(--sl-border-radius-medium);
17391
+ --sl-input-border-radius-medium: var(--sl-border-radius-medium);
17392
+ --sl-input-border-radius-large: var(--sl-border-radius-medium);
17393
+
17394
+ --sl-input-font-family: var(--sl-font-sans);
17395
+ --sl-input-font-weight: var(--sl-font-weight-normal);
17396
+ --sl-input-font-size-small: var(--sl-font-size-small);
17397
+ --sl-input-font-size-medium: var(--sl-font-size-medium);
17398
+ --sl-input-font-size-large: var(--sl-font-size-large);
17399
+ --sl-input-letter-spacing: var(--sl-letter-spacing-normal);
17400
+
17401
+ --sl-input-color: var(--sl-color-neutral-700);
17402
+ --sl-input-color-hover: var(--sl-color-neutral-700);
17403
+ --sl-input-color-focus: var(--sl-color-neutral-700);
17404
+ --sl-input-color-disabled: var(--sl-color-neutral-900);
17405
+ --sl-input-icon-color: var(--sl-color-neutral-400);
17406
+ --sl-input-icon-color-hover: var(--sl-color-neutral-500);
17407
+ --sl-input-icon-color-focus: var(--sl-color-neutral-500);
17408
+ --sl-input-placeholder-color: var(--sl-color-neutral-400);
17409
+ --sl-input-placeholder-color-disabled: var(--sl-color-neutral-500);
17410
+ --sl-input-spacing-small: var(--sl-spacing-small);
17411
+ --sl-input-spacing-medium: var(--sl-spacing-medium);
17412
+ --sl-input-spacing-large: var(--sl-spacing-large);
17413
+
17414
+ --sl-input-focus-ring-color: hsl(198.6 88.7% 48.4% / 40%);
17415
+ --sl-input-focus-ring-offset: 0;
17416
+
17417
+ --sl-input-filled-background-color: var(--sl-color-neutral-100);
17418
+ --sl-input-filled-background-color-hover: var(
17419
+ --sl-color-neutral-100
17420
+ );
17421
+ --sl-input-filled-background-color-focus: var(
17422
+ --sl-color-neutral-100
17423
+ );
17424
+ --sl-input-filled-background-color-disabled: var(
17425
+ --sl-color-neutral-100
17426
+ );
17427
+ --sl-input-filled-color: var(--sl-color-neutral-800);
17428
+ --sl-input-filled-color-hover: var(--sl-color-neutral-800);
17429
+ --sl-input-filled-color-focus: var(--sl-color-neutral-700);
17430
+ --sl-input-filled-color-disabled: var(--sl-color-neutral-800);
17431
+
17432
+ --sl-input-label-font-size-small: var(--sl-font-size-small);
17433
+ --sl-input-label-font-size-medium: var(--sl-font-size-medium);
17434
+ --sl-input-label-font-size-large: var(--sl-font-size-large);
17435
+ --sl-input-label-color: inherit;
17436
+
17437
+ --sl-input-help-text-font-size-small: var(--sl-font-size-x-small);
17438
+ --sl-input-help-text-font-size-medium: var(--sl-font-size-small);
17439
+ --sl-input-help-text-font-size-large: var(--sl-font-size-medium);
17440
+ --sl-input-help-text-color: var(--sl-color-neutral-500);
17441
+
17442
+ --sl-toggle-size-small: 0.875rem;
17443
+ --sl-toggle-size-medium: 1.125rem;
17444
+ --sl-toggle-size-large: 1.375rem;
17445
+
17446
+ --sl-overlay-background-color: hsl(240 3.8% 46.1% / 33%);
17447
+
17448
+ --sl-panel-background-color: var(--sl-color-neutral-0);
17449
+ --sl-panel-border-color: var(--sl-color-neutral-300);
17450
+ --sl-panel-border-width: 1px;
17451
+
17452
+ --sl-tooltip-border-radius: var(--sl-border-radius-medium);
17453
+ --sl-tooltip-background-color: var(--sl-color-neutral-800);
17454
+ --sl-tooltip-color: var(--sl-color-neutral-0);
17455
+ --sl-tooltip-font-family: var(--sl-font-sans);
17456
+ --sl-tooltip-font-weight: var(--sl-font-weight-normal);
17457
+ --sl-tooltip-font-size: var(--sl-font-size-small);
17458
+ --sl-tooltip-line-height: var(--sl-line-height-dense);
17459
+ --sl-tooltip-padding: var(--sl-spacing-2x-small)
17460
+ var(--sl-spacing-x-small);
17461
+ --sl-tooltip-arrow-size: 6px;
17462
+
17463
+ --sl-z-index-drawer: 700;
17464
+ --sl-z-index-dialog: 800;
17465
+ --sl-z-index-dropdown: 900;
17466
+ --sl-z-index-toast: 950;
17467
+ --sl-z-index-tooltip: 1000;
17468
+
17469
+ --td-footer-background-color: #09090b;
17470
+ --td-footer-color: #e4e4e7;
17471
+
17472
+ --td-code-block-toolbar-cell-background-color: #e2e8f0;
17473
+ --td-code-block-highlighted-background-color: #dbeafe;
17474
+
17475
+ --td-card-color: 'inherit';
17476
+ --td-card-background-color: var(--sl-color-neutral-0);
17477
+ --td-card-background-hover-color: var(--sl-color-neutral-50);
17478
+ --td-card-border-color: rgba(24, 24, 27, 0.08);
17479
+ --td-card-box-shadow-1: rgba(24, 24, 27, 0.02);
17480
+ --td-card-box-shadow-1-y: 3px;
17481
+ --td-card-box-shadow-1-blur: 6px;
17482
+ --td-card-box-shadow-2: rgba(24, 24, 27, 0.04);
17483
+ --td-card-box-shadow-2-y: 2px;
17484
+ --td-card-box-shadow-2-blur: 7px;
17485
+
17486
+ --td-card-hover-border-color: rgba(24, 24, 27, 0.15);
17487
+ --td-card-hover-box-shadow-1: rgba(24, 24, 27, 0.05);
17488
+ --td-card-hover-box-shadow-1-y: 3px;
17489
+ --td-card-hover-box-shadow-1-blur: 6px;
17490
+ --td-card-hover-box-shadow-2: rgba(24, 24, 27, 0.1);
17491
+ --td-card-hover-box-shadow-2-y: 8px;
17492
+ --td-card-hover-box-shadow-2-blur: 15px;
17493
+
17494
+ --td-body-gradient-line-color: #ffffff;
17495
+
17496
+ --td-editor-text-color-blue: hsl(221, 100%, 50%);
17497
+ --td-editor-text-color-purple: hsl(291, 100%, 39%);
17498
+ --td-editor-text-color-red: hsl(4, 100%, 40%);
17499
+ --td-editor-text-color-green: hsl(122, 100%, 23%);
17500
+
17501
+ --td-editor-bg-color-blue: hsl(221, 100%, 50%, 0.1);
17502
+ --td-editor-bg-color-purple: hsl(291, 100%, 39%, 0.1);
17503
+ --td-editor-bg-color-red: hsl(4, 100%, 40%, 0.1);
17504
+ --td-editor-bg-color-green: hsl(122, 100%, 23%, 0.1);
17505
+ }
17506
+ `;
17507
+ var themeDark = `
17508
+ :host,
17509
+ .theme-dark {
17510
+ color-scheme: dark;
17511
+
17512
+ --sl-color-primary-950: #f0f9ff;
17513
+ --sl-color-primary-900: #e0f2fe;
17514
+ --sl-color-primary-800: #bae6fd;
17515
+ --sl-color-primary-700: #93c5fd;
17516
+ --sl-color-primary-600: #60a5fa;
17517
+ --sl-color-primary-500: #3b82f6;
17518
+ --sl-color-primary-400: #2563eb;
17519
+ --sl-color-primary-300: #1d4ed8;
17520
+ --sl-color-primary-200: #1e40af;
17521
+ --sl-color-primary-100: #1e3a8a;
17522
+ --sl-color-primary-50: #172554;
17523
+
17524
+ --sl-color-success-950: #f0fdf4;
17525
+ --sl-color-success-900: #dcfce7;
17526
+ --sl-color-success-800: #bbf7d0;
17527
+ --sl-color-success-700: #86efac;
17528
+ --sl-color-success-600: #4ade80;
17529
+ --sl-color-success-500: #22c55e;
17530
+ --sl-color-success-400: #16a34a;
17531
+ --sl-color-success-300: #15803d;
17532
+ --sl-color-success-200: #166534;
17533
+ --sl-color-success-100: #14532d;
17534
+ --sl-color-success-50: #052e16;
17535
+
17536
+ --sl-color-warning-950: #fffbeb;
17537
+ --sl-color-warning-900: #fef3c7;
17538
+ --sl-color-warning-800: #fde68a;
17539
+ --sl-color-warning-700: #fcd34d;
17540
+ --sl-color-warning-600: #fbbf24;
17541
+ --sl-color-warning-500: #f59e0b;
17542
+ --sl-color-warning-400: #d97706;
17543
+ --sl-color-warning-300: #b45309;
17544
+ --sl-color-warning-200: #92400e;
17545
+ --sl-color-warning-100: #78350f;
17546
+ --sl-color-warning-50: #451a03;
17547
+
17548
+ --sl-color-danger-950: #fef2f2;
17549
+ --sl-color-danger-900: #fee2e2;
17550
+ --sl-color-danger-800: #fecaca;
17551
+ --sl-color-danger-700: #fca5a5;
17552
+ --sl-color-danger-600: #f87171;
17553
+ --sl-color-danger-500: #ef4444;
17554
+ --sl-color-danger-400: #dc2626;
17555
+ --sl-color-danger-300: #b91c1c;
17556
+ --sl-color-danger-200: #991b1b;
17557
+ --sl-color-danger-100: #7f1d1d;
17558
+ --sl-color-danger-50: #450a0a;
17559
+
17560
+ --sl-color-neutral-950: #fafafa;
17561
+ --sl-color-neutral-900: #f4f4f5;
17562
+ --sl-color-neutral-800: #e4e4e7;
17563
+ --sl-color-neutral-700: #d4d4d8;
17564
+ --sl-color-neutral-600: #a1a1aa;
17565
+ --sl-color-neutral-500: #71717a;
17566
+
17567
+ --sl-color-neutral-400: #71717a;
17568
+ --sl-color-neutral-300: #52525b;
17569
+ --sl-color-neutral-200: #3f3f46;
17570
+ --sl-color-neutral-100: #27272a;
17571
+ --sl-color-neutral-50: #18181b;
17572
+ --sl-color-neutral-0: #09090b;
17573
+ --sl-color-neutral-1000: hsl(0, 0%, 100%);
17574
+
17575
+ --sl-border-base: var(--be-border-base);
17576
+ --sl-border-radius-small: calc(var(--sl-border-base) * 0.1875);
17577
+ --sl-border-radius-medium: calc(var(--sl-border-base) * 0.25);
17578
+ --sl-border-radius-large: calc(var(--sl-border-base) * 0.5);
17579
+ --sl-border-radius-x-large: var(
17580
+ --sl-border-base
17581
+ );
17582
+
17583
+ --sl-border-radius-circle: 50%;
17584
+ --sl-border-radius-pill: 9999px;
17585
+
17586
+ --sl-shadow-x-small: 0 1px 2px rgb(0 0 0 / 18%);
17587
+ --sl-shadow-small: 0 1px 2px rgb(0 0 0 / 24%);
17588
+ --sl-shadow-medium: 0 2px 4px rgb(0 0 0 / 24%);
17589
+ --sl-shadow-large: var(
17590
+ --be-shadow-large,
17591
+ 0 2px 8px rgb(0 0 0 / 24%)
17592
+ );
17593
+ --sl-shadow-x-large: 0 4px 16px rgb(0 0 0 / 24%);
17594
+
17595
+ --sl-spacing-base: var(--be-spacing-base, 1rem);
17596
+ --sl-spacing-3x-small: calc(
17597
+ var(--sl-spacing-base) * 0.125
17598
+ );
17599
+ --sl-spacing-2x-small: calc(
17600
+ var(--sl-spacing-base) * 0.25
17601
+ );
17602
+ --sl-spacing-1_5x-small: calc(
17603
+ var(--sl-spacing-base) * 0.375
17604
+ );
17605
+ --sl-spacing-x-small: calc(
17606
+ var(--sl-spacing-base) * 0.5
17607
+ );
17608
+ --sl-spacing-small: calc(
17609
+ var(--sl-spacing-base) * 0.75
17610
+ );
17611
+ --sl-spacing-medium: var(--sl-spacing-base);
17612
+ --sl-spacing-large: calc(
17613
+ var(--sl-spacing-base) * 1.25
17614
+ );
17615
+ --sl-spacing-x-large: calc(
17616
+ var(--sl-spacing-base) * 1.75
17617
+ );
17618
+ --sl-spacing-2x-large: calc(
17619
+ var(--sl-spacing-base) * 2.25
17620
+ );
17621
+ --sl-spacing-3x-large: calc(
17622
+ var(--sl-spacing-base) * 3
17623
+ );
17624
+ --sl-spacing-4x-large: calc(
17625
+ var(--sl-spacing-base) * 4.5
17626
+ );
17627
+ --sl-spacing-5x-large: calc(var(--sl-spacing-base) * 5);
17628
+
17629
+ --indent-size: var(--sl-spacing-large);
17630
+
17631
+ --sl-transition-x-slow: 1000ms;
17632
+ --sl-transition-slow: 500ms;
17633
+ --sl-transition-medium: 250ms;
17634
+ --sl-transition-fast: 150ms;
17635
+ --sl-transition-x-fast: 50ms;
17636
+
17637
+ --sl-font-mono: var(
17638
+ --be-font-mono,
17639
+ SFMono-Regular,
17640
+ Consolas,
17641
+ 'Liberation Mono',
17642
+ Menlo,
17643
+ monospace
17644
+ );
17645
+ --sl-font-sans: var(
17646
+ --be-font-sans,
17647
+ -apple-system,
17648
+ BlinkMacSystemFont,
17649
+ 'Segoe UI',
17650
+ Roboto,
17651
+ Helvetica,
17652
+ Arial,
17653
+ sans-serif,
17654
+ 'Apple Color Emoji',
17655
+ 'Segoe UI Emoji',
17656
+ 'Segoe UI Symbol'
17657
+ );
17658
+ --sl-font-serif: var(
17659
+ --be-font-serif,
17660
+ Georgia,
17661
+ 'Times New Roman',
17662
+ serif
17663
+ );
17664
+
17665
+ --sl-font-size-base: var(--be-font-size-base, 1rem);
17666
+ --sl-font-size-2x-small: calc(var(--sl-font-size-base) * 0.625);
17667
+ --sl-font-size-x-small: calc(var(--sl-font-size-base) * 0.75);
17668
+ --sl-font-size-small: calc(var(--sl-font-size-base) * 0.875);
17669
+ --sl-font-size-medium: var(--sl-font-size-base);
17670
+ --sl-font-size-large: calc(var(--sl-font-size-base) * 1.25);
17671
+ --sl-font-size-x-large: calc(var(--sl-font-size-base) * 1.5);
17672
+ --sl-font-size-2x-large: calc(var(--sl-font-size-base) * 2.25);
17673
+ --sl-font-size-3x-large: calc(var(--sl-font-size-base) * 3);
17674
+ --sl-font-size-4x-large: calc(var(--sl-font-size-base) * 4.5);
17675
+
17676
+ --sl-font-weight-light: 300;
17677
+ --sl-font-weight-normal: 400;
17678
+ --sl-font-weight-semibold: 500;
17679
+ --sl-font-weight-bold: 700;
17680
+
17681
+ --sl-letter-spacing-denser: -0.03em;
17682
+ --sl-letter-spacing-dense: -0.015em;
17683
+ --sl-letter-spacing-normal: normal;
17684
+ --sl-letter-spacing-loose: 0.075em;
17685
+ --sl-letter-spacing-looser: 0.15em;
17686
+
17687
+ --sl-line-height-base: 1;
17688
+ --sl-line-height-x-denser: calc(var(--sl-line-height-base) * 1.1);
17689
+ --sl-line-height-denser: calc(var(--sl-line-height-base) * 1.2);
17690
+ --sl-line-height-dense: calc(var(--sl-line-height-base) * 1.4);
17691
+ --sl-line-height-subnormal: calc(var(--sl-line-height-base) * 1.6);
17692
+ --sl-line-height-normal: calc(var(--sl-line-height-base) * 1.8);
17693
+ --sl-line-height-loose: calc(var(--sl-line-height-base) * 2.2);
17694
+ --sl-line-height-looser: calc(var(--sl-line-height-base) * 2.6);
17695
+
17696
+ --sl-focus-ring-color: var(--sl-color-primary-700);
17697
+ --sl-focus-ring-style: solid;
17698
+ --sl-focus-ring-width: var(--be-focus-ring-width, 1px);
17699
+ --sl-focus-ring: var(--sl-focus-ring-style)
17700
+ var(--sl-focus-ring-width) var(--sl-focus-ring-color);
17701
+ --sl-focus-ring-offset: 1px;
17702
+
17703
+ --sl-button-font-size-small: var(--sl-font-size-x-small);
17704
+ --sl-button-font-size-medium: var(--sl-font-size-small);
17705
+ --sl-button-font-size-large: var(--sl-font-size-medium);
17706
+
17707
+ --sl-input-height-base: 1rem;
17708
+ --sl-input-height-small: calc(var(--sl-input-height-base) * 1.875);
17709
+ --sl-input-height-medium: calc(var(--sl-input-height-base) * 2.5);
17710
+ --sl-input-height-large: calc(var(--sl-input-height-base) * 3.125);
17711
+
17712
+ --sl-input-background-color: var(--sl-color-neutral-0);
17713
+ --sl-input-background-color-hover: var(--sl-input-background-color);
17714
+ --sl-input-background-color-focus: var(--sl-input-background-color);
17715
+ --sl-input-background-color-disabled: var(--sl-color-neutral-100);
17716
+ --sl-input-border-color: var(--sl-color-neutral-300);
17717
+ --sl-input-border-color-hover: var(--sl-color-neutral-400);
17718
+ --sl-input-border-color-focus: var(--sl-color-primary-500);
17719
+ --sl-input-border-color-disabled: var(--sl-color-neutral-300);
17720
+ --sl-input-border-width: 1px;
17721
+ --sl-input-required-content: '*';
17722
+ --sl-input-required-content-offset: -2px;
17723
+ --sl-input-required-content-color: var(--sl-input-label-color);
17724
+
17725
+ --sl-input-border-radius-small: var(--sl-border-radius-medium);
17726
+ --sl-input-border-radius-medium: var(--sl-border-radius-medium);
17727
+ --sl-input-border-radius-large: var(--sl-border-radius-medium);
17728
+
17729
+ --sl-input-font-family: var(--sl-font-sans);
17730
+ --sl-input-font-weight: var(--sl-font-weight-normal);
17731
+ --sl-input-font-size-small: var(--sl-font-size-small);
17732
+ --sl-input-font-size-medium: var(--sl-font-size-medium);
17733
+ --sl-input-font-size-large: var(--sl-font-size-large);
17734
+ --sl-input-letter-spacing: var(--sl-letter-spacing-normal);
17735
+
17736
+ --sl-input-color: var(--sl-color-neutral-700);
17737
+ --sl-input-color-hover: var(--sl-color-neutral-700);
17738
+ --sl-input-color-focus: var(--sl-color-neutral-700);
17739
+ --sl-input-color-disabled: var(--sl-color-neutral-900);
17740
+ --sl-input-icon-color: var(--sl-color-neutral-400);
17741
+ --sl-input-icon-color-hover: var(--sl-color-neutral-500);
17742
+ --sl-input-icon-color-focus: var(--sl-color-neutral-500);
17743
+ --sl-input-placeholder-color: var(--sl-color-neutral-400);
17744
+ --sl-input-placeholder-color-disabled: var(--sl-color-neutral-500);
17745
+ --sl-input-spacing-small: var(--sl-spacing-small);
17746
+ --sl-input-spacing-medium: var(--sl-spacing-medium);
17747
+ --sl-input-spacing-large: var(--sl-spacing-large);
17748
+
17749
+ --sl-input-focus-ring-color: hsl(198.6 88.7% 48.4% / 40%);
17750
+ --sl-input-focus-ring-offset: 0;
17751
+
17752
+ --sl-input-filled-background-color: var(--sl-color-neutral-100);
17753
+ --sl-input-filled-background-color-hover: var(
17754
+ --sl-color-neutral-100
17755
+ );
17756
+ --sl-input-filled-background-color-focus: var(
17757
+ --sl-color-neutral-100
17758
+ );
17759
+ --sl-input-filled-background-color-disabled: var(
17760
+ --sl-color-neutral-100
17761
+ );
17762
+ --sl-input-filled-color: var(--sl-color-neutral-800);
17763
+ --sl-input-filled-color-hover: var(--sl-color-neutral-800);
17764
+ --sl-input-filled-color-focus: var(--sl-color-neutral-700);
17765
+ --sl-input-filled-color-disabled: var(--sl-color-neutral-800);
17766
+
17767
+ --sl-input-label-font-size-small: var(--sl-font-size-small);
17768
+ --sl-input-label-font-size-medium: var(--sl-font-size-medium);
17769
+ --sl-input-label-font-size-large: var(--sl-font-size-large);
17770
+ --sl-input-label-color: inherit;
17771
+
17772
+ --sl-input-help-text-font-size-small: var(--sl-font-size-x-small);
17773
+ --sl-input-help-text-font-size-medium: var(--sl-font-size-small);
17774
+ --sl-input-help-text-font-size-large: var(--sl-font-size-medium);
17775
+ --sl-input-help-text-color: var(--sl-color-neutral-500);
17776
+
17777
+ --sl-toggle-size-small: 0.875rem;
17778
+ --sl-toggle-size-medium: 1.125rem;
17779
+ --sl-toggle-size-large: 1.375rem;
17780
+
17781
+ --sl-overlay-background-color: hsla(0, 0%, 100%, 0.05);
17782
+
17783
+ --sl-panel-background-color: var(--sl-color-neutral-0);
17784
+ --sl-panel-border-color: var(--sl-color-neutral-300);
17785
+ --sl-panel-border-width: 1px;
17786
+
17787
+ --sl-tooltip-border-radius: var(--sl-border-radius-medium);
17788
+ --sl-tooltip-background-color: var(--sl-color-neutral-800);
17789
+ --sl-tooltip-color: var(--sl-color-neutral-0);
17790
+ --sl-tooltip-font-family: var(--sl-font-sans);
17791
+ --sl-tooltip-font-weight: var(--sl-font-weight-normal);
17792
+ --sl-tooltip-font-size: var(--sl-font-size-small);
17793
+ --sl-tooltip-line-height: var(--sl-line-height-dense);
17794
+ --sl-tooltip-padding: var(--sl-spacing-2x-small)
17795
+ var(--sl-spacing-x-small);
17796
+ --sl-tooltip-arrow-size: 6px;
17797
+
17798
+ --sl-z-index-drawer: 700;
17799
+ --sl-z-index-dialog: 800;
17800
+ --sl-z-index-dropdown: 900;
17801
+ --sl-z-index-toast: 950;
17802
+ --sl-z-index-tooltip: 1000;
17803
+
17804
+ --td-footer-background-color: #09090b;
17805
+ --td-footer-color: #e4e4e7;
17806
+
17807
+ --td-code-block-toolbar-cell-background-color: #09090b;
17808
+ --td-code-block-highlighted-background-color: #1e293b;
17809
+
17810
+ --td-card-color: 'inherit';
17811
+ --td-card-background-color: var(--sl-color-neutral-0);
17812
+ --td-card-background-hover-color: var(--sl-color-neutral-50);
17813
+ --td-card-border-color: rgba(255, 255, 255, 0.1);
17814
+ --td-card-box-shadow-1: rgba(0, 0, 0, 0.05);
17815
+ --td-card-box-shadow-1-y: 3px;
17816
+ --td-card-box-shadow-1-blur: 6px;
17817
+ --td-card-box-shadow-2: rgba(0, 0, 0, 0.1);
17818
+ --td-card-box-shadow-2-y: 8px;
17819
+ --td-card-box-shadow-2-blur: 15px;
17820
+
17821
+ --td-card-hover-border-color: rgba(255, 255, 255, 0.2);
17822
+ --td-card-hover-box-shadow-1: rgba(0, 0, 0, 0.04);
17823
+ --td-card-hover-box-shadow-1-y: 5px;
17824
+ --td-card-hover-box-shadow-1-blur: 10px;
17825
+ --td-card-hover-box-shadow-2: rgba(0, 0, 0, 0.3);
17826
+ --td-card-hover-box-shadow-2-y: 15px;
17827
+ --td-card-hover-box-shadow-2-blur: 25px;
17828
+
17829
+ --td-body-gradient-line-color: #27272a47;
17830
+
17831
+ --td-editor-text-color-blue: hsl(221, 100%, 70%);
17832
+ --td-editor-text-color-purple: hsl(291, 100%, 65%);
17833
+ --td-editor-text-color-red: hsl(4, 100%, 63%);
17834
+ --td-editor-text-color-green: hsl(122, 100%, 34%);
17835
+
17836
+ --td-editor-bg-color-blue: hsl(221, 100%, 70%, 0.2);
17837
+ --td-editor-bg-color-purple: hsl(291, 100%, 65%, 0.2);
17838
+ --td-editor-bg-color-red: hsl(4, 100%, 63%, 0.2);
17839
+ --td-editor-bg-color-green: hsl(122, 100%, 34%, 0.2);
17840
+ }
17841
+ `;
17842
+
17162
17843
  // src/theme/ThemeProvider.tsx
17163
17844
  var import_react98 = require("react");
17164
- var import_jsx_runtime117 = require("react/jsx-runtime");
17165
- var themeVariablesMap = {
17845
+
17846
+ // src/theme/constants.ts
17847
+ var themeSettingsMap = {
17166
17848
  borderBase: "--be-border-base",
17167
17849
  fontSans: "--be-font-sans",
17168
17850
  fontSerif: "--be-font-serif",
17169
17851
  fontMono: "--be-font-mono",
17170
17852
  spacingBase: "--be-spacing-base",
17171
- fontSizeBase: "--be-font-size-base"
17853
+ fontSizeBase: "--be-font-size-base",
17854
+ focusRingWidth: "--be-focus-ring-width",
17855
+ shadowLarge: "--be-shadow-large"
17172
17856
  };
17857
+ var defaultThemeSettings = {
17858
+ borderBase: "1rem",
17859
+ fontSans: "'Inter', sans-serif",
17860
+ fontSerif: "Georgia, 'Times New Roman', serif",
17861
+ fontMono: "Menlo, Monaco, 'Courier New', monospace",
17862
+ focusRingWidth: "1px",
17863
+ shadowLarge: "rgba(50, 50, 93, 0.25) 0px 6px 12px -2px, rgba(0, 0, 0, 0.3) 0px 3px 7px -3px",
17864
+ spacingBase: "1rem",
17865
+ fontSizeBase: "1rem"
17866
+ };
17867
+
17868
+ // src/theme/ThemeProvider.tsx
17869
+ var import_jsx_runtime117 = require("react/jsx-runtime");
17173
17870
  var ThemeContext = (0, import_react98.createContext)(
17174
17871
  void 0
17175
17872
  );
17176
17873
  function ThemeProvider({
17177
17874
  theme,
17178
- themeVariables = {},
17875
+ themeSettings = {},
17179
17876
  children
17180
17877
  }) {
17181
17878
  const rootElementRef = (0, import_react98.useRef)(null);
@@ -17202,20 +17899,33 @@ function ThemeProvider({
17202
17899
  );
17203
17900
  rootElementRef.current?.classList.add(`theme-${effectiveTheme}`);
17204
17901
  }, [effectiveTheme]);
17205
- return /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(ThemeContext.Provider, { value: { theme, effectiveTheme }, children: /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
17206
- "div",
17902
+ return /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(ThemeContext.Provider, { value: { theme, effectiveTheme }, children: /* @__PURE__ */ (0, import_jsx_runtime117.jsxs)(
17903
+ "article",
17207
17904
  {
17208
17905
  ref: rootElementRef,
17209
- className: "theme-settings",
17906
+ className: "be-article",
17210
17907
  style: {
17211
17908
  ...Object.fromEntries(
17212
- Object.entries(themeVariables).map(([key, value]) => [
17213
- themeVariablesMap[key],
17909
+ Object.entries({
17910
+ ...defaultThemeSettings,
17911
+ themeSettings
17912
+ }).map(([key, value]) => [
17913
+ themeSettingsMap[key],
17214
17914
  value
17215
17915
  ])
17216
17916
  )
17217
17917
  },
17218
- children
17918
+ children: [
17919
+ /* @__PURE__ */ (0, import_jsx_runtime117.jsx)(
17920
+ "style",
17921
+ {
17922
+ dangerouslySetInnerHTML: {
17923
+ __html: effectiveTheme === "light" ? themeLight : themeDark
17924
+ }
17925
+ }
17926
+ ),
17927
+ children
17928
+ ]
17219
17929
  }
17220
17930
  ) });
17221
17931
  }
@@ -17235,10 +17945,10 @@ var RESET_EDITING_MODE = "RESET_EDITING_MODE";
17235
17945
  var BlockEditorContext = import_react99.default.createContext(null);
17236
17946
  function BlockEditor(props) {
17237
17947
  const {
17238
- themeSettings,
17239
17948
  editable = true,
17240
17949
  editorState,
17241
17950
  theme,
17951
+ themeSettings,
17242
17952
  onChange,
17243
17953
  children,
17244
17954
  renderSettings
@@ -17254,9 +17964,6 @@ function BlockEditor(props) {
17254
17964
  const drawerRef = (0, import_react99.useRef)(null);
17255
17965
  const [isBlockEditorReady, setBlockEditorReady] = (0, import_react99.useState)(false);
17256
17966
  const { historyState } = useSharedHistoryContext();
17257
- const [blockEditorStyleVars, setBlockEditorStyleVars] = (0, import_react99.useState)({
17258
- "--be-ol-list-style-type": "decimal"
17259
- });
17260
17967
  const handleChange = (0, import_react99.useCallback)(
17261
17968
  (editorState2, _editor, tags) => {
17262
17969
  if (onChange && !tags?.has("new_state") && !tags?.has("history-merge")) {
@@ -17402,83 +18109,63 @@ function BlockEditor(props) {
17402
18109
  },
17403
18110
  drawer: drawerRef.current,
17404
18111
  isBlockEditorReady,
17405
- blockEditorStyleVars,
17406
- setBlockEditorStyleVars: (value) => {
17407
- setBlockEditorStyleVars({
17408
- ...blockEditorStyleVars,
17409
- ...value
17410
- });
17411
- },
17412
18112
  renderSettings: renderSettings ? renderSettings : () => /* @__PURE__ */ (0, import_jsx_runtime118.jsx)("div", {})
17413
18113
  },
17414
- children: /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(ThemeProvider, { theme, themeVariables: themeSettings, children: /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(ResizeObserver, { children: /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
17415
- "article",
17416
- {
17417
- className: "be-article",
17418
- style: { ...blockEditorStyleVars },
17419
- children: /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(SharedHistoryContext, { children: /* @__PURE__ */ (0, import_jsx_runtime118.jsxs)(NodeProvider, { children: [
17420
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
17421
- "main",
17422
- {
17423
- className: `${settingsPanelSwitch === "on" ? "narrow" : ""}`,
17424
- children: /* @__PURE__ */ (0, import_jsx_runtime118.jsxs)(
17425
- import_LexicalComposer.LexicalComposer,
17426
- {
17427
- initialConfig: { ...initialConfig },
17428
- children: [
17429
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
17430
- EditorRefPlugin,
17431
- {
17432
- onMountRef: (editor) => editorRef.current = editor
17433
- }
17434
- ),
17435
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(AutoFocusPlugin, {}),
17436
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(AutoBottomParagraphPlugin, {}),
17437
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
17438
- import_LexicalHistoryPlugin10.HistoryPlugin,
17439
- {
17440
- externalHistoryState: historyState
17441
- }
17442
- ),
17443
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
17444
- import_LexicalOnChangePlugin.OnChangePlugin,
17445
- {
17446
- onChange: handleChange,
17447
- ignoreSelectionChange: true
17448
- }
17449
- ),
17450
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(OnNestedChangePlugin, { onChange: handleChange }),
17451
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
17452
- import_LexicalRichTextPlugin7.RichTextPlugin,
17453
- {
17454
- contentEditable: /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(ContentEditable, {}),
17455
- placeholder: null,
17456
- ErrorBoundary: import_LexicalErrorBoundary9.LexicalErrorBoundary
17457
- }
17458
- ),
17459
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(NodePastePlugin, {}),
17460
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(import_LexicalListPlugin2.ListPlugin, {}),
17461
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(ListLevelLimitPlugin, {}),
17462
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(import_LexicalTabIndentationPlugin2.TabIndentationPlugin, {}),
17463
- children,
17464
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(TypeaheadMenuPlugin, {}),
17465
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(TypeaheadMenuAgentPlugin, {}),
17466
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(NodeMouseAnchorPlugin, {}),
17467
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(NodeMousePlugin, {}),
17468
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(TextToolbarPlugin, {}),
17469
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(TextToolbarAgentPlugin, {}),
17470
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(TypeaheadVariableAgentPlugin, {}),
17471
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(VariableComponentPlugin, {}),
17472
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(MarkdownPlugin, {})
17473
- ]
17474
- }
17475
- )
17476
- }
17477
- ),
17478
- /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(Drawer, { ref: drawerRef })
17479
- ] }) })
17480
- }
17481
- ) }) })
18114
+ children: /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(ResizeObserver, { children: /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(ThemeProvider, { theme, themeSettings, children: /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(SharedHistoryContext, { children: /* @__PURE__ */ (0, import_jsx_runtime118.jsxs)(NodeProvider, { children: [
18115
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
18116
+ "main",
18117
+ {
18118
+ className: `${settingsPanelSwitch === "on" ? "narrow" : ""}`,
18119
+ children: /* @__PURE__ */ (0, import_jsx_runtime118.jsxs)(import_LexicalComposer.LexicalComposer, { initialConfig: { ...initialConfig }, children: [
18120
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
18121
+ EditorRefPlugin,
18122
+ {
18123
+ onMountRef: (editor) => editorRef.current = editor
18124
+ }
18125
+ ),
18126
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(AutoFocusPlugin, {}),
18127
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(AutoBottomParagraphPlugin, {}),
18128
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
18129
+ import_LexicalHistoryPlugin10.HistoryPlugin,
18130
+ {
18131
+ externalHistoryState: historyState
18132
+ }
18133
+ ),
18134
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
18135
+ import_LexicalOnChangePlugin.OnChangePlugin,
18136
+ {
18137
+ onChange: handleChange,
18138
+ ignoreSelectionChange: true
18139
+ }
18140
+ ),
18141
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(OnNestedChangePlugin, { onChange: handleChange }),
18142
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(
18143
+ import_LexicalRichTextPlugin7.RichTextPlugin,
18144
+ {
18145
+ contentEditable: /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(ContentEditable, {}),
18146
+ placeholder: null,
18147
+ ErrorBoundary: import_LexicalErrorBoundary9.LexicalErrorBoundary
18148
+ }
18149
+ ),
18150
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(NodePastePlugin, {}),
18151
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(import_LexicalListPlugin2.ListPlugin, {}),
18152
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(ListLevelLimitPlugin, {}),
18153
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(import_LexicalTabIndentationPlugin2.TabIndentationPlugin, {}),
18154
+ children,
18155
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(TypeaheadMenuPlugin, {}),
18156
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(TypeaheadMenuAgentPlugin, {}),
18157
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(NodeMouseAnchorPlugin, {}),
18158
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(NodeMousePlugin, {}),
18159
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(TextToolbarPlugin, {}),
18160
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(TextToolbarAgentPlugin, {}),
18161
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(TypeaheadVariableAgentPlugin, {}),
18162
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(VariableComponentPlugin, {}),
18163
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(MarkdownPlugin, {})
18164
+ ] })
18165
+ }
18166
+ ),
18167
+ /* @__PURE__ */ (0, import_jsx_runtime118.jsx)(Drawer, { ref: drawerRef })
18168
+ ] }) }) }) })
17482
18169
  }
17483
18170
  );
17484
18171
  }
@@ -17492,24 +18179,31 @@ var useBlockEditor = () => {
17492
18179
  return context;
17493
18180
  };
17494
18181
 
18182
+ // src/BlockEditorStyle.tsx
18183
+ var import_jsx_runtime119 = require("react/jsx-runtime");
18184
+ function BlockEditorStyle(props) {
18185
+ const { children, theme, themeSettings } = props;
18186
+ return /* @__PURE__ */ (0, import_jsx_runtime119.jsx)(ThemeProvider, { theme, themeSettings, children });
18187
+ }
18188
+
17495
18189
  // src/modules/Callout.tsx
17496
18190
  var import_react100 = require("react");
17497
- var import_jsx_runtime119 = require("react/jsx-runtime");
18191
+ var import_jsx_runtime120 = require("react/jsx-runtime");
17498
18192
  function Callout() {
17499
18193
  const { registerModule } = useBlockEditor();
17500
18194
  (0, import_react100.useEffect)(() => {
17501
18195
  registerModule("Callout");
17502
18196
  }, [registerModule]);
17503
- return /* @__PURE__ */ (0, import_jsx_runtime119.jsx)(CalloutBoxPlugin, {});
18197
+ return /* @__PURE__ */ (0, import_jsx_runtime120.jsx)(CalloutBoxPlugin, {});
17504
18198
  }
17505
18199
 
17506
18200
  // src/plugins/TreeViewPlugin/index.tsx
17507
18201
  var import_LexicalComposerContext64 = require("@lexical/react/LexicalComposerContext");
17508
18202
  var import_LexicalTreeView = require("@lexical/react/LexicalTreeView");
17509
- var import_jsx_runtime120 = require("react/jsx-runtime");
18203
+ var import_jsx_runtime121 = require("react/jsx-runtime");
17510
18204
  function TreeViewPlugin() {
17511
18205
  const [editor] = (0, import_LexicalComposerContext64.useLexicalComposerContext)();
17512
- return /* @__PURE__ */ (0, import_jsx_runtime120.jsx)(
18206
+ return /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(
17513
18207
  import_LexicalTreeView.TreeView,
17514
18208
  {
17515
18209
  viewClassName: "tree-view-output",
@@ -17525,25 +18219,25 @@ function TreeViewPlugin() {
17525
18219
 
17526
18220
  // src/modules/Debug.tsx
17527
18221
  var import_react101 = require("react");
17528
- var import_jsx_runtime121 = require("react/jsx-runtime");
18222
+ var import_jsx_runtime122 = require("react/jsx-runtime");
17529
18223
  function Debug() {
17530
18224
  const { registerModule } = useBlockEditor();
17531
18225
  (0, import_react101.useEffect)(() => {
17532
18226
  registerModule("Debug");
17533
18227
  }, [registerModule]);
17534
- return /* @__PURE__ */ (0, import_jsx_runtime121.jsx)(TreeViewPlugin, {});
18228
+ return /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(TreeViewPlugin, {});
17535
18229
  }
17536
18230
 
17537
18231
  // src/modules/Image.tsx
17538
18232
  var import_react102 = require("react");
17539
- var import_jsx_runtime122 = require("react/jsx-runtime");
18233
+ var import_jsx_runtime123 = require("react/jsx-runtime");
17540
18234
  function Image(props) {
17541
18235
  const { imageSettings } = props;
17542
18236
  const { registerModule } = useBlockEditor();
17543
18237
  (0, import_react102.useEffect)(() => {
17544
18238
  registerModule("Image");
17545
18239
  }, [registerModule]);
17546
- return /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(import_jsx_runtime122.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime122.jsx)(ImagePlugin, { imageSettings }) });
18240
+ return /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(import_jsx_runtime123.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(ImagePlugin, { imageSettings }) });
17547
18241
  }
17548
18242
 
17549
18243
  // src/plugins/LinkToolbarPlugin/LinkToolbarPlugin.tsx
@@ -17554,7 +18248,7 @@ var import_lexical98 = require("lexical");
17554
18248
  var import_debounce6 = __toESM(require("lodash-es/debounce"));
17555
18249
  var import_lucide_react27 = require("lucide-react");
17556
18250
  var import_react103 = require("react");
17557
- var import_jsx_runtime123 = require("react/jsx-runtime");
18251
+ var import_jsx_runtime124 = require("react/jsx-runtime");
17558
18252
  function LinkToolbarPlugin() {
17559
18253
  const [editor] = (0, import_LexicalComposerContext65.useLexicalComposerContext)();
17560
18254
  const popupToolbarRef = (0, import_react103.useRef)(null);
@@ -17664,12 +18358,12 @@ function LinkToolbarPlugin() {
17664
18358
  }, [editor]);
17665
18359
  const linkUrl = linkNode?.linkUrl;
17666
18360
  const linkTitle = linkNode?.linkUrl;
17667
- return /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
18361
+ return /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
17668
18362
  PopupToolbar,
17669
18363
  {
17670
18364
  ref: popupToolbarRef,
17671
18365
  onEscape: handleClose,
17672
- toolbar: /* @__PURE__ */ (0, import_jsx_runtime123.jsxs)(
18366
+ toolbar: /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)(
17673
18367
  "div",
17674
18368
  {
17675
18369
  style: {
@@ -17682,23 +18376,23 @@ function LinkToolbarPlugin() {
17682
18376
  padding: "var(--sl-spacing-2x-small) var(--sl-spacing-x-small) var(--sl-spacing-2x-small) var(--sl-spacing-medium)"
17683
18377
  },
17684
18378
  children: [
17685
- /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("a", { href: linkUrl, target: linkNode?.linkTarget || "", children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
18379
+ /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("a", { href: linkUrl, target: linkNode?.linkTarget || "", children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
17686
18380
  "sl-tooltip",
17687
18381
  {
17688
18382
  style: { "--show-delay": "1800" },
17689
18383
  hoist: true,
17690
18384
  content: linkUrl || "[Empty URL]",
17691
- children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("span", { className: "line-short-20", children: linkTitle })
18385
+ children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("span", { className: "line-short-20", children: linkTitle })
17692
18386
  }
17693
18387
  ) }) }),
17694
- /* @__PURE__ */ (0, import_jsx_runtime123.jsxs)(Stack, { className: "stack__row", children: [
17695
- /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
18388
+ /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)(Stack, { className: "stack__row", children: [
18389
+ /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
17696
18390
  "sl-tooltip",
17697
18391
  {
17698
18392
  style: { "--show-delay": "1800" },
17699
18393
  hoist: "hoist",
17700
18394
  content: "Edit Link",
17701
- children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
18395
+ children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
17702
18396
  Button,
17703
18397
  {
17704
18398
  size: "small",
@@ -17737,13 +18431,13 @@ function LinkToolbarPlugin() {
17737
18431
  )
17738
18432
  }
17739
18433
  ) }),
17740
- /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
18434
+ /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
17741
18435
  "sl-tooltip",
17742
18436
  {
17743
18437
  style: { "--show-delay": "1800" },
17744
18438
  hoist: "hoist",
17745
18439
  content: "Remove Link",
17746
- children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
18440
+ children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
17747
18441
  Button,
17748
18442
  {
17749
18443
  size: "small",
@@ -17778,13 +18472,13 @@ function LinkToolbarPlugin() {
17778
18472
  )
17779
18473
  }
17780
18474
  ) }),
17781
- /* @__PURE__ */ (0, import_jsx_runtime123.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
18475
+ /* @__PURE__ */ (0, import_jsx_runtime124.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
17782
18476
  "sl-tooltip",
17783
18477
  {
17784
18478
  style: { "--show-delay": "1800" },
17785
18479
  hoist: "hoist",
17786
18480
  content: "Close",
17787
- children: /* @__PURE__ */ (0, import_jsx_runtime123.jsx)(
18481
+ children: /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(
17788
18482
  Button,
17789
18483
  {
17790
18484
  size: "small",
@@ -17807,15 +18501,15 @@ function LinkToolbarPlugin() {
17807
18501
 
17808
18502
  // src/modules/Link.tsx
17809
18503
  var import_react104 = require("react");
17810
- var import_jsx_runtime124 = require("react/jsx-runtime");
18504
+ var import_jsx_runtime125 = require("react/jsx-runtime");
17811
18505
  function Link() {
17812
18506
  const { registerModule } = useBlockEditor();
17813
18507
  (0, import_react104.useEffect)(() => {
17814
18508
  registerModule("Link");
17815
18509
  }, [registerModule]);
17816
- return /* @__PURE__ */ (0, import_jsx_runtime124.jsxs)(import_jsx_runtime124.Fragment, { children: [
17817
- /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(LinkEditorPlugin, {}),
17818
- /* @__PURE__ */ (0, import_jsx_runtime124.jsx)(LinkToolbarPlugin, {})
18510
+ return /* @__PURE__ */ (0, import_jsx_runtime125.jsxs)(import_jsx_runtime125.Fragment, { children: [
18511
+ /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(LinkEditorPlugin, {}),
18512
+ /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(LinkToolbarPlugin, {})
17819
18513
  ] });
17820
18514
  }
17821
18515
 
@@ -17824,7 +18518,7 @@ var import_LexicalComposerContext66 = require("@lexical/react/LexicalComposerCon
17824
18518
  var import_utils36 = require("@lexical/utils");
17825
18519
  var import_lexical99 = require("lexical");
17826
18520
  var import_react105 = require("react");
17827
- var import_jsx_runtime125 = require("react/jsx-runtime");
18521
+ var import_jsx_runtime126 = require("react/jsx-runtime");
17828
18522
  var INSERT_ESSAY_QUESTION_COMMAND = (0, import_lexical99.createCommand)("INSERT_ESSAY_QUESTION_COMMAND");
17829
18523
  function EssayQuestionPlugin() {
17830
18524
  const [editor] = (0, import_LexicalComposerContext66.useLexicalComposerContext)();
@@ -17862,7 +18556,7 @@ function EssayQuestionPlugin() {
17862
18556
  )
17863
18557
  );
17864
18558
  }, [editor]);
17865
- return /* @__PURE__ */ (0, import_jsx_runtime125.jsx)(import_jsx_runtime125.Fragment, {});
18559
+ return /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(import_jsx_runtime126.Fragment, {});
17866
18560
  }
17867
18561
 
17868
18562
  // src/plugins/FinancialStatementQuestionPlugin/FinancialStatementQuestionSettings.tsx
@@ -17890,7 +18584,7 @@ function validatePointsInput6(input) {
17890
18584
  }
17891
18585
 
17892
18586
  // src/plugins/FinancialStatementQuestionPlugin/FinancialStatementQuestionSettings.tsx
17893
- var import_jsx_runtime126 = require("react/jsx-runtime");
18587
+ var import_jsx_runtime127 = require("react/jsx-runtime");
17894
18588
  function FinancialStatementQuestionSettings(props) {
17895
18589
  const { nodeKey } = props;
17896
18590
  const [editor] = (0, import_LexicalComposerContext67.useLexicalComposerContext)();
@@ -17909,7 +18603,7 @@ function FinancialStatementQuestionSettings(props) {
17909
18603
  if (!foundNode) {
17910
18604
  return null;
17911
18605
  }
17912
- return /* @__PURE__ */ (0, import_jsx_runtime126.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
18606
+ return /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
17913
18607
  TextInput,
17914
18608
  {
17915
18609
  ref: pointsTextInputRef,
@@ -17943,7 +18637,7 @@ var import_LexicalComposerContext68 = require("@lexical/react/LexicalComposerCon
17943
18637
  var import_utils37 = require("@lexical/utils");
17944
18638
  var import_lexical101 = require("lexical");
17945
18639
  var import_react107 = require("react");
17946
- var import_jsx_runtime127 = require("react/jsx-runtime");
18640
+ var import_jsx_runtime128 = require("react/jsx-runtime");
17947
18641
  var INSERT_FINANCIAL_STATEMENT_QUESTION_COMMAND = (0, import_lexical101.createCommand)("INSERT_FINANCIAL_STATEMENT_QUESTION_COMMAND");
17948
18642
  function FinancialStatementQuestionPlugin() {
17949
18643
  const {
@@ -18008,21 +18702,21 @@ function FinancialStatementQuestionPlugin() {
18008
18702
  }
18009
18703
  }
18010
18704
  }, [isBlockEditorReady]);
18011
- return /* @__PURE__ */ (0, import_jsx_runtime127.jsxs)(import_jsx_runtime127.Fragment, { children: [
18012
- drawer && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
18705
+ return /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
18706
+ drawer && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
18013
18707
  StickyToPosition,
18014
18708
  {
18015
18709
  ref: settingsPanelStickyRef,
18016
18710
  container: drawer,
18017
18711
  children: (data, position, isVisible) => {
18018
- return /* @__PURE__ */ (0, import_jsx_runtime127.jsx)("div", { style: { width: position.width }, children: /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
18712
+ return /* @__PURE__ */ (0, import_jsx_runtime128.jsx)("div", { style: { width: position.width }, children: /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
18019
18713
  SettingsCard,
18020
18714
  {
18021
18715
  isVisible: !!isVisible,
18022
18716
  container: drawer,
18023
18717
  title: "Financial Statement Settings",
18024
18718
  onClose: toggleSettingsPanelSwitch,
18025
- children: isVisible && /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(
18719
+ children: isVisible && /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(
18026
18720
  FinancialStatementQuestionSettings,
18027
18721
  {
18028
18722
  nodeKey: data.nodeKey
@@ -18034,32 +18728,32 @@ function FinancialStatementQuestionPlugin() {
18034
18728
  }
18035
18729
  }
18036
18730
  ),
18037
- /* @__PURE__ */ (0, import_jsx_runtime127.jsx)(FillInTheBlankSpaceSettingsPlugin, {})
18731
+ /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(FillInTheBlankSpaceSettingsPlugin, {})
18038
18732
  ] });
18039
18733
  }
18040
18734
 
18041
18735
  // src/modules/Questions.tsx
18042
18736
  var import_react108 = require("react");
18043
- var import_jsx_runtime128 = require("react/jsx-runtime");
18737
+ var import_jsx_runtime129 = require("react/jsx-runtime");
18044
18738
  function Questions() {
18045
18739
  const { registerModule } = useBlockEditor();
18046
18740
  (0, import_react108.useEffect)(() => {
18047
18741
  registerModule("Questions");
18048
18742
  }, [registerModule]);
18049
- return /* @__PURE__ */ (0, import_jsx_runtime128.jsxs)(import_jsx_runtime128.Fragment, { children: [
18050
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(MultipleOptionQuestionPlugin, {}),
18051
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(ShortAnswerQuestionPlugin, {}),
18052
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(MatchingQuestionPlugin, {}),
18053
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(FillInTheBlankQuestionPlugin, {}),
18054
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(JournalEntryQuestionPlugin, {}),
18055
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(FinancialStatementQuestionPlugin, {}),
18056
- /* @__PURE__ */ (0, import_jsx_runtime128.jsx)(EssayQuestionPlugin, {})
18743
+ return /* @__PURE__ */ (0, import_jsx_runtime129.jsxs)(import_jsx_runtime129.Fragment, { children: [
18744
+ /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(MultipleOptionQuestionPlugin, {}),
18745
+ /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(ShortAnswerQuestionPlugin, {}),
18746
+ /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(MatchingQuestionPlugin, {}),
18747
+ /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(FillInTheBlankQuestionPlugin, {}),
18748
+ /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(JournalEntryQuestionPlugin, {}),
18749
+ /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(FinancialStatementQuestionPlugin, {}),
18750
+ /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(EssayQuestionPlugin, {})
18057
18751
  ] });
18058
18752
  }
18059
18753
 
18060
18754
  // src/modules/SettingsPanel.tsx
18061
18755
  var import_react109 = require("react");
18062
- var import_jsx_runtime129 = require("react/jsx-runtime");
18756
+ var import_jsx_runtime130 = require("react/jsx-runtime");
18063
18757
  function SettingsPanel(props) {
18064
18758
  const { defaultOpen = true } = props;
18065
18759
  const { registerModule, openSettingsPanel } = useBlockEditor();
@@ -18071,7 +18765,7 @@ function SettingsPanel(props) {
18071
18765
  }
18072
18766
  }, 50);
18073
18767
  }, [registerModule, defaultOpen, openSettingsPanel]);
18074
- return /* @__PURE__ */ (0, import_jsx_runtime129.jsx)(SettingsPanelPlugin, {});
18768
+ return /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(SettingsPanelPlugin, {});
18075
18769
  }
18076
18770
 
18077
18771
  // src/plugins/VariablesPlugin/VariableSettingsPlugin.tsx
@@ -18082,7 +18776,7 @@ var import_LexicalComposerContext69 = require("@lexical/react/LexicalComposerCon
18082
18776
  var import_lexical102 = require("lexical");
18083
18777
  var import_lucide_react28 = require("lucide-react");
18084
18778
  var import_react110 = require("react");
18085
- var import_jsx_runtime130 = require("react/jsx-runtime");
18779
+ var import_jsx_runtime131 = require("react/jsx-runtime");
18086
18780
  var controlGridStyle = {
18087
18781
  width: "100%",
18088
18782
  display: "flex",
@@ -18304,8 +18998,8 @@ function VariableSettings(props) {
18304
18998
  if (!currentVariableNode) {
18305
18999
  return null;
18306
19000
  }
18307
- return /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)(import_jsx_runtime130.Fragment, { children: [
18308
- /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("div", { style: formFieldStyle, children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
19001
+ return /* @__PURE__ */ (0, import_jsx_runtime131.jsxs)(import_jsx_runtime131.Fragment, { children: [
19002
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { style: formFieldStyle, children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
18309
19003
  Button,
18310
19004
  {
18311
19005
  className: "button__fullwidth",
@@ -18324,10 +19018,10 @@ function VariableSettings(props) {
18324
19018
  variant: "default"
18325
19019
  }
18326
19020
  ) }),
18327
- /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)("div", { style: formFieldStyle, children: [
18328
- /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("div", { style: formFieldLabel, children: "Name" }),
18329
- /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)("div", { style: controlGridStyle, children: [
18330
- /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("div", { style: { flexGrow: 1 }, children: isSettingsEditingMode ? /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
19021
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsxs)("div", { style: formFieldStyle, children: [
19022
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { style: formFieldLabel, children: "Name" }),
19023
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsxs)("div", { style: controlGridStyle, children: [
19024
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { style: { flexGrow: 1 }, children: isSettingsEditingMode ? /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
18331
19025
  "form",
18332
19026
  {
18333
19027
  onSubmit: (e) => {
@@ -18335,7 +19029,7 @@ function VariableSettings(props) {
18335
19029
  e.preventDefault();
18336
19030
  updateVariableName();
18337
19031
  },
18338
- children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
19032
+ children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
18339
19033
  TextInput,
18340
19034
  {
18341
19035
  ref: variableNameInputRef,
@@ -18347,7 +19041,7 @@ function VariableSettings(props) {
18347
19041
  }
18348
19042
  )
18349
19043
  }
18350
- ) : /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
19044
+ ) : /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
18351
19045
  DropdownButton,
18352
19046
  {
18353
19047
  className: "button__fullwidth button__left_aligned",
@@ -18360,7 +19054,7 @@ function VariableSettings(props) {
18360
19054
  menu: variablesMenu
18361
19055
  }
18362
19056
  ) }),
18363
- /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("div", { style: { flexGrow: 0 }, children: isSettingsEditingMode ? /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
19057
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { style: { flexGrow: 0 }, children: isSettingsEditingMode ? /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
18364
19058
  Button,
18365
19059
  {
18366
19060
  StartIcon: import_lucide_react28.Save,
@@ -18368,7 +19062,7 @@ function VariableSettings(props) {
18368
19062
  size: "small",
18369
19063
  onClick: updateVariableName
18370
19064
  }
18371
- ) : /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
19065
+ ) : /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
18372
19066
  Button,
18373
19067
  {
18374
19068
  StartIcon: import_lucide_react28.Pencil,
@@ -18381,9 +19075,9 @@ function VariableSettings(props) {
18381
19075
  ) })
18382
19076
  ] })
18383
19077
  ] }),
18384
- /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)("div", { style: formFieldStyle, children: [
18385
- /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("div", { style: formFieldLabel, children: "Type" }),
18386
- /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
19078
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsxs)("div", { style: formFieldStyle, children: [
19079
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { style: formFieldLabel, children: "Type" }),
19080
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
18387
19081
  DropdownButton,
18388
19082
  {
18389
19083
  className: "button__fullwidth button__left_aligned",
@@ -18397,9 +19091,9 @@ function VariableSettings(props) {
18397
19091
  }
18398
19092
  )
18399
19093
  ] }),
18400
- currentVariableNode.getVariableFormat() && /* @__PURE__ */ (0, import_jsx_runtime130.jsxs)("div", { style: formFieldStyle, children: [
18401
- /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("div", { style: formFieldLabel, children: "Format" }),
18402
- /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
19094
+ currentVariableNode.getVariableFormat() && /* @__PURE__ */ (0, import_jsx_runtime131.jsxs)("div", { style: formFieldStyle, children: [
19095
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { style: formFieldLabel, children: "Format" }),
19096
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
18403
19097
  DropdownButton,
18404
19098
  {
18405
19099
  className: "button__fullwidth button__left_aligned",
@@ -18413,7 +19107,7 @@ function VariableSettings(props) {
18413
19107
  }
18414
19108
  )
18415
19109
  ] }),
18416
- /* @__PURE__ */ (0, import_jsx_runtime130.jsx)("div", { style: { width: "100%", display: "f" }, children: /* @__PURE__ */ (0, import_jsx_runtime130.jsx)(
19110
+ /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { style: { width: "100%", display: "f" }, children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
18417
19111
  Button,
18418
19112
  {
18419
19113
  size: "small",
@@ -18455,7 +19149,7 @@ function VariableSettings(props) {
18455
19149
  }
18456
19150
 
18457
19151
  // src/plugins/VariablesPlugin/VariableSettingsPlugin.tsx
18458
- var import_jsx_runtime131 = require("react/jsx-runtime");
19152
+ var import_jsx_runtime132 = require("react/jsx-runtime");
18459
19153
  function VariableSettingsPlugin() {
18460
19154
  const {
18461
19155
  registerSettingsPanel,
@@ -18474,20 +19168,20 @@ function VariableSettingsPlugin() {
18474
19168
  }
18475
19169
  }
18476
19170
  }, [isBlockEditorReady]);
18477
- return /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(import_jsx_runtime131.Fragment, { children: drawer && /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
19171
+ return /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(import_jsx_runtime132.Fragment, { children: drawer && /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
18478
19172
  StickyToPosition,
18479
19173
  {
18480
19174
  ref: settingsPanelStickyRef,
18481
19175
  container: drawer,
18482
19176
  children: (data, position, isVisible) => {
18483
- return /* @__PURE__ */ (0, import_jsx_runtime131.jsx)("div", { style: { width: position.width }, children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
19177
+ return /* @__PURE__ */ (0, import_jsx_runtime132.jsx)("div", { style: { width: position.width }, children: /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
18484
19178
  SettingsCard,
18485
19179
  {
18486
19180
  isVisible: !!isVisible,
18487
19181
  container: drawer,
18488
19182
  title: "Variable Settings",
18489
19183
  onClose: toggleSettingsPanelSwitch,
18490
- children: /* @__PURE__ */ (0, import_jsx_runtime131.jsx)(
19184
+ children: /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(
18491
19185
  VariableSettings,
18492
19186
  {
18493
19187
  nodeKey: data.nodeKey,
@@ -18509,7 +19203,7 @@ var import_lexical103 = require("lexical");
18509
19203
  var import_debounce7 = __toESM(require("lodash-es/debounce"));
18510
19204
  var import_lucide_react29 = require("lucide-react");
18511
19205
  var import_react112 = require("react");
18512
- var import_jsx_runtime132 = require("react/jsx-runtime");
19206
+ var import_jsx_runtime133 = require("react/jsx-runtime");
18513
19207
  function VariableToolbarPlugin() {
18514
19208
  const [editor] = (0, import_LexicalComposerContext70.useLexicalComposerContext)();
18515
19209
  const popupToolbarRef = (0, import_react112.useRef)(null);
@@ -18702,12 +19396,12 @@ function VariableToolbarPlugin() {
18702
19396
  ];
18703
19397
  return resultList;
18704
19398
  }, [toolbarState]);
18705
- return /* @__PURE__ */ (0, import_jsx_runtime132.jsx)(PopupToolbar, { ref: popupToolbarRef, menu: menuItems });
19399
+ return /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(PopupToolbar, { ref: popupToolbarRef, menu: menuItems });
18706
19400
  }
18707
19401
 
18708
19402
  // src/modules/Variables.tsx
18709
19403
  var import_react113 = require("react");
18710
- var import_jsx_runtime133 = require("react/jsx-runtime");
19404
+ var import_jsx_runtime134 = require("react/jsx-runtime");
18711
19405
  function Variables(props) {
18712
19406
  const { variablesSettings } = props;
18713
19407
  const { registerModule, setEditingModeDataCallback } = useBlockEditor();
@@ -18721,16 +19415,17 @@ function Variables(props) {
18721
19415
  };
18722
19416
  });
18723
19417
  }, [variablesSettings, setEditingModeDataCallback]);
18724
- return /* @__PURE__ */ (0, import_jsx_runtime133.jsxs)(VariablesProvider, { variablesSettings, children: [
18725
- /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(TypeaheadVariablePlugin, {}),
18726
- /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(VariableSettingsPlugin, {}),
18727
- /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(VariableToolbarPlugin, {}),
18728
- /* @__PURE__ */ (0, import_jsx_runtime133.jsx)(VariableToolbarAgentPlugin, {})
19418
+ return /* @__PURE__ */ (0, import_jsx_runtime134.jsxs)(VariablesProvider, { variablesSettings, children: [
19419
+ /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(TypeaheadVariablePlugin, {}),
19420
+ /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(VariableSettingsPlugin, {}),
19421
+ /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(VariableToolbarPlugin, {}),
19422
+ /* @__PURE__ */ (0, import_jsx_runtime134.jsx)(VariableToolbarAgentPlugin, {})
18729
19423
  ] });
18730
19424
  }
18731
19425
  // Annotate the CommonJS export names for ESM import in node:
18732
19426
  0 && (module.exports = {
18733
19427
  BlockEditor,
19428
+ BlockEditorStyle,
18734
19429
  Callout,
18735
19430
  Debug,
18736
19431
  Image,