@byline/richtext-lexical 6.10.0 → 6.11.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.
Files changed (60) hide show
  1. package/dist/field/content-editable.css +22 -18
  2. package/dist/field/editor-component.css +33 -29
  3. package/dist/field/editor.css +1218 -1214
  4. package/dist/field/extensions/admonition/admonition-modal.css +20 -16
  5. package/dist/field/extensions/admonition/admonition-node.css +114 -110
  6. package/dist/field/extensions/admonition/icons/danger-icon.css +13 -9
  7. package/dist/field/extensions/admonition/icons/note-icon.css +13 -9
  8. package/dist/field/extensions/admonition/icons/tip-icon.css +13 -9
  9. package/dist/field/extensions/admonition/icons/warning-icon.css +13 -9
  10. package/dist/field/extensions/auto-embed/auto-embed-modal.css +14 -10
  11. package/dist/field/extensions/floating-text-format/index.css +130 -126
  12. package/dist/field/extensions/inline-image/inline-image-modal.css +120 -116
  13. package/dist/field/extensions/inline-image/inline-image-node-component.css +243 -239
  14. package/dist/field/extensions/layout/insert-layout-modal.css +16 -12
  15. package/dist/field/extensions/link/floating-link-editor.css +113 -109
  16. package/dist/field/extensions/link/link-target-fields.css +61 -57
  17. package/dist/field/normalize/adapted-notice.css +2 -4
  18. package/dist/field/plugins/table-plugin/table-modal.css +17 -13
  19. package/dist/field/themes/lexical-editor-theme.css +471 -467
  20. package/dist/field/ui/button.css +28 -24
  21. package/dist/field/ui/checkbox.css +43 -39
  22. package/dist/field/ui/color-picker.css +69 -65
  23. package/dist/field/ui/dialog.css +18 -14
  24. package/dist/field/ui/input.css +23 -19
  25. package/dist/field/ui/modal.css +66 -62
  26. package/dist/field/ui/placeholder.css +25 -21
  27. package/dist/field/ui/select.css +32 -28
  28. package/dist/field/ui/text-area.css +29 -25
  29. package/dist/richtext-field_module.css +21 -17
  30. package/package.json +6 -6
  31. package/src/field/content-editable.css +31 -17
  32. package/src/field/editor-component.css +56 -40
  33. package/src/field/editor.css +1248 -1232
  34. package/src/field/extensions/admonition/admonition-modal.css +32 -16
  35. package/src/field/extensions/admonition/admonition-node.css +105 -89
  36. package/src/field/extensions/admonition/icons/danger-icon.css +25 -9
  37. package/src/field/extensions/admonition/icons/note-icon.css +25 -9
  38. package/src/field/extensions/admonition/icons/tip-icon.css +25 -9
  39. package/src/field/extensions/admonition/icons/warning-icon.css +25 -9
  40. package/src/field/extensions/auto-embed/auto-embed-modal.css +25 -9
  41. package/src/field/extensions/floating-text-format/index.css +142 -126
  42. package/src/field/extensions/inline-image/inline-image-modal.css +144 -128
  43. package/src/field/extensions/inline-image/inline-image-node-component.css +258 -242
  44. package/src/field/extensions/layout/insert-layout-modal.css +28 -12
  45. package/src/field/extensions/link/floating-link-editor.css +129 -113
  46. package/src/field/extensions/link/link-target-fields.css +68 -52
  47. package/src/field/normalize/adapted-notice.css +5 -4
  48. package/src/field/plugins/table-plugin/table-modal.css +29 -13
  49. package/src/field/themes/lexical-editor-theme.css +508 -494
  50. package/src/field/ui/button.css +46 -30
  51. package/src/field/ui/checkbox.css +62 -46
  52. package/src/field/ui/color-picker.css +89 -73
  53. package/src/field/ui/dialog.css +30 -14
  54. package/src/field/ui/input.css +38 -22
  55. package/src/field/ui/modal.css +81 -65
  56. package/src/field/ui/placeholder.css +36 -20
  57. package/src/field/ui/select.css +46 -30
  58. package/src/field/ui/text-area.css +45 -29
  59. package/src/lexical-editor.tsx +2 -0
  60. package/src/richtext-field.module.css +38 -22
@@ -1,128 +1,144 @@
1
- .link-editor {
2
- position: absolute;
3
- top: 0;
4
- left: 0;
5
- z-index: 10;
6
- max-width: 400px;
7
- width: 100%;
8
- opacity: 0;
9
- background-color: #fff;
10
- box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
11
- border-radius: 6px;
12
- transition: opacity 0.5s;
13
- will-change: transform;
14
- }
1
+ @layer base,
2
+ byline-base,
3
+ theme,
4
+ byline-theme,
5
+ byline-functional,
6
+ byline-typography,
7
+ components,
8
+ byline-components,
9
+ overrides,
10
+ byline-utilities,
11
+ utilities;
15
12
 
16
- .link-editor .button {
17
- width: 20px;
18
- height: 20px;
19
- display: inline-block;
20
- padding: 6px;
21
- border-radius: 6px;
22
- cursor: pointer;
23
- margin: 0 2px;
24
- }
13
+ @layer byline-components.primitives, byline-components.cms;
25
14
 
26
- .link-editor .button.hovered {
27
- width: 20px;
28
- height: 20px;
29
- display: inline-block;
30
- background-color: #eee;
31
- }
15
+ @layer byline-components.cms {
16
+ .link-editor {
17
+ position: absolute;
18
+ top: 0;
19
+ left: 0;
20
+ z-index: 10;
21
+ max-width: 400px;
22
+ width: 100%;
23
+ opacity: 0;
24
+ background-color: #fff;
25
+ box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
26
+ border-radius: 6px;
27
+ transition: opacity 0.5s;
28
+ will-change: transform;
29
+ }
32
30
 
33
- .link-editor .button i,
34
- .actions i {
35
- background-size: contain;
36
- display: inline-block;
37
- height: 20px;
38
- width: 20px;
39
- vertical-align: -0.25em;
40
- }
31
+ .link-editor .button {
32
+ width: 20px;
33
+ height: 20px;
34
+ display: inline-block;
35
+ padding: 6px;
36
+ border-radius: 6px;
37
+ cursor: pointer;
38
+ margin: 0 2px;
39
+ }
41
40
 
42
- .link-editor .button.active,
43
- .toolbar .button.active {
44
- background-color: rgb(223, 232, 250);
45
- }
41
+ .link-editor .button.hovered {
42
+ width: 20px;
43
+ height: 20px;
44
+ display: inline-block;
45
+ background-color: #eee;
46
+ }
46
47
 
47
- .link-editor .link-input {
48
- display: block;
49
- min-height: 26px;
50
- box-sizing: border-box;
51
- margin: 8px 4px 8px 10px;
52
- padding: 2px;
53
- border-radius: 8px;
54
- background-color: #eee;
55
- font-size: 15px;
56
- color: rgb(5, 5, 5);
57
- border: 0;
58
- outline: 0;
59
- position: relative;
60
- font-family: inherit;
61
- }
48
+ .link-editor .button i,
49
+ .actions i {
50
+ background-size: contain;
51
+ display: inline-block;
52
+ height: 20px;
53
+ width: 20px;
54
+ vertical-align: -0.25em;
55
+ }
62
56
 
63
- .link-editor .link-view a {
64
- display: block;
65
- word-break: break-word;
66
- width: calc(100% - 33px);
67
- }
57
+ .link-editor .button.active,
58
+ .toolbar .button.active {
59
+ background-color: rgb(223, 232, 250);
60
+ }
68
61
 
69
- .link-editor div.link-edit {
70
- background-image: url(../../images/icons/pencil-fill.svg);
71
- background-size: 16px;
72
- background-position: center;
73
- background-repeat: no-repeat;
74
- width: 35px;
75
- vertical-align: -0.25em;
76
- position: absolute;
77
- right: 30px;
78
- top: 0;
79
- bottom: 0;
80
- cursor: pointer;
81
- }
62
+ .link-editor .link-input {
63
+ display: block;
64
+ min-height: 26px;
65
+ box-sizing: border-box;
66
+ margin: 8px 4px 8px 10px;
67
+ padding: 2px;
68
+ border-radius: 8px;
69
+ background-color: #eee;
70
+ font-size: 15px;
71
+ color: rgb(5, 5, 5);
72
+ border: 0;
73
+ outline: 0;
74
+ position: relative;
75
+ font-family: inherit;
76
+ }
82
77
 
83
- .link-editor div.link-trash {
84
- background-image: url(../../images/icons/trash.svg);
85
- background-size: 16px;
86
- background-position: center;
87
- background-repeat: no-repeat;
88
- width: 35px;
89
- vertical-align: -0.25em;
90
- position: absolute;
91
- right: 0;
92
- top: 0;
93
- bottom: 0;
94
- cursor: pointer;
95
- }
78
+ .link-editor .link-view a {
79
+ display: block;
80
+ word-break: break-word;
81
+ width: calc(100% - 33px);
82
+ }
96
83
 
97
- .link-editor .link-input a {
98
- color: rgb(33, 111, 219);
99
- text-decoration: none;
100
- display: block;
101
- white-space: nowrap;
102
- overflow: hidden;
103
- margin-right: 30px;
104
- text-overflow: ellipsis;
105
- }
84
+ .link-editor div.link-edit {
85
+ background-image: url(../../images/icons/pencil-fill.svg);
86
+ background-size: 16px;
87
+ background-position: center;
88
+ background-repeat: no-repeat;
89
+ width: 35px;
90
+ vertical-align: -0.25em;
91
+ position: absolute;
92
+ right: 30px;
93
+ top: 0;
94
+ bottom: 0;
95
+ cursor: pointer;
96
+ }
106
97
 
107
- .link-editor .link-input a:hover {
108
- text-decoration: underline;
109
- }
98
+ .link-editor div.link-trash {
99
+ background-image: url(../../images/icons/trash.svg);
100
+ background-size: 16px;
101
+ background-position: center;
102
+ background-repeat: no-repeat;
103
+ width: 35px;
104
+ vertical-align: -0.25em;
105
+ position: absolute;
106
+ right: 0;
107
+ top: 0;
108
+ bottom: 0;
109
+ cursor: pointer;
110
+ }
110
111
 
111
- .link-editor .font-size-wrapper,
112
- .link-editor .font-family-wrapper {
113
- display: flex;
114
- margin: 0 4px;
115
- }
112
+ .link-editor .link-input a {
113
+ color: rgb(33, 111, 219);
114
+ text-decoration: none;
115
+ display: block;
116
+ white-space: nowrap;
117
+ overflow: hidden;
118
+ margin-right: 30px;
119
+ text-overflow: ellipsis;
120
+ }
116
121
 
117
- .link-editor select {
118
- padding: 6px;
119
- border: none;
120
- background-color: rgba(0, 0, 0, 0.075);
121
- border-radius: 4px;
122
- }
122
+ .link-editor .link-input a:hover {
123
+ text-decoration: underline;
124
+ }
123
125
 
124
- .dark {
125
- .link-editor {
126
- background-color: var(--canvas-800);
126
+ .link-editor .font-size-wrapper,
127
+ .link-editor .font-family-wrapper {
128
+ display: flex;
129
+ margin: 0 4px;
130
+ }
131
+
132
+ .link-editor select {
133
+ padding: 6px;
134
+ border: none;
135
+ background-color: rgba(0, 0, 0, 0.075);
136
+ border-radius: 4px;
137
+ }
138
+
139
+ .dark {
140
+ .link-editor {
141
+ background-color: var(--canvas-800);
142
+ }
127
143
  }
128
144
  }
@@ -1,3 +1,17 @@
1
+ @layer base,
2
+ byline-base,
3
+ theme,
4
+ byline-theme,
5
+ byline-functional,
6
+ byline-typography,
7
+ components,
8
+ byline-components,
9
+ overrides,
10
+ byline-utilities,
11
+ utilities;
12
+
13
+ @layer byline-components.primitives, byline-components.cms;
14
+
1
15
  /**
2
16
  * Link-target picker — the "Target document" frame.
3
17
  *
@@ -14,68 +28,70 @@
14
28
  * break without warning. The values are what keep the two in step.
15
29
  */
16
30
 
17
- .byline-link-target-frame {
18
- margin-top: 0.25rem;
19
- padding: 0.5rem;
20
- border: var(--border-width-thin, 1px) var(--border-style-solid, solid) var(--field-border);
21
- border-radius: var(--border-radius-md, 6px);
22
- }
31
+ @layer byline-components.cms {
32
+ .byline-link-target-frame {
33
+ margin-top: 0.25rem;
34
+ padding: 0.5rem;
35
+ border: var(--border-width-thin, 1px) var(--border-style-solid, solid) var(--field-border);
36
+ border-radius: var(--border-radius-md, 6px);
37
+ }
23
38
 
24
- /* The chosen document: summary on the left, actions pinned right. */
25
- .byline-link-target-tile {
26
- display: flex;
27
- align-items: flex-start;
28
- justify-content: space-between;
29
- gap: var(--spacing-8, 0.5rem);
30
- padding: var(--spacing-8, 0.5rem);
31
- border: var(--border-width-thin, 1px) var(--border-style-solid, solid) var(--primary-500);
32
- border-radius: var(--border-radius-md, 6px);
33
- font-size: var(--font-size-xs);
34
- }
39
+ /* The chosen document: summary on the left, actions pinned right. */
40
+ .byline-link-target-tile {
41
+ display: flex;
42
+ align-items: flex-start;
43
+ justify-content: space-between;
44
+ gap: var(--spacing-8, 0.5rem);
45
+ padding: var(--spacing-8, 0.5rem);
46
+ border: var(--border-width-thin, 1px) var(--border-style-solid, solid) var(--primary-500);
47
+ border-radius: var(--border-radius-md, 6px);
48
+ font-size: var(--font-size-xs);
49
+ }
35
50
 
36
- .byline-link-target-summary {
37
- display: flex;
38
- min-width: 0;
39
- flex-direction: column;
40
- gap: 0.125rem;
41
- }
51
+ .byline-link-target-summary {
52
+ display: flex;
53
+ min-width: 0;
54
+ flex-direction: column;
55
+ gap: 0.125rem;
56
+ }
42
57
 
43
- /* Small "type" line above the value — the target collection's label. */
44
- .byline-link-target-kind {
45
- color: var(--gray-500);
46
- }
58
+ /* Small "type" line above the value — the target collection's label. */
59
+ .byline-link-target-kind {
60
+ color: var(--gray-500);
61
+ }
47
62
 
48
- .byline-link-target-value {
49
- overflow: hidden;
50
- color: var(--gray-900);
51
- text-overflow: ellipsis;
52
- white-space: nowrap;
53
- }
63
+ .byline-link-target-value {
64
+ overflow: hidden;
65
+ color: var(--gray-900);
66
+ text-overflow: ellipsis;
67
+ white-space: nowrap;
68
+ }
54
69
 
55
- .byline-link-target-actions {
56
- display: flex;
57
- flex-shrink: 0;
58
- align-items: center;
59
- gap: var(--spacing-4, 0.25rem);
60
- }
70
+ .byline-link-target-actions {
71
+ display: flex;
72
+ flex-shrink: 0;
73
+ align-items: center;
74
+ gap: var(--spacing-4, 0.25rem);
75
+ }
61
76
 
62
- .byline-link-target-actions .byline-button {
63
- color: var(--gray-900);
64
- }
77
+ .byline-link-target-actions .byline-button {
78
+ color: var(--gray-900);
79
+ }
65
80
 
66
- :is([data-theme="dark"], .dark) {
67
- /* A darker hairline than `--field-border` gives on this surface: the
81
+ :is([data-theme="dark"], .dark) {
82
+ /* A darker hairline than `--field-border` gives on this surface: the
68
83
  modal sits on an already-raised panel, so the default reads as a
69
84
  bright outline rather than a division. */
70
- .byline-link-target-frame {
71
- border-color: var(--canvas-700, var(--field-border));
72
- }
85
+ .byline-link-target-frame {
86
+ border-color: var(--canvas-700, var(--field-border));
87
+ }
73
88
 
74
- .byline-link-target-value {
75
- color: var(--gray-100);
76
- }
89
+ .byline-link-target-value {
90
+ color: var(--gray-100);
91
+ }
77
92
 
78
- .byline-link-target-actions .byline-button {
79
- color: var(--gray-200);
93
+ .byline-link-target-actions .byline-button {
94
+ color: var(--gray-200);
95
+ }
80
96
  }
81
97
  }
@@ -6,9 +6,10 @@
6
6
  byline-typography,
7
7
  components,
8
8
  byline-components,
9
- utilities,
10
- byline-utilities;
11
-
9
+ overrides,
10
+ byline-utilities,
11
+ utilities;
12
+ @layer byline-components.primitives, byline-components.cms;
12
13
  /**
13
14
  * Content-adaptation notices.
14
15
  *
@@ -21,7 +22,7 @@
21
22
  * Declared in `byline-components` so the layer order the admin
22
23
  * establishes governs them, rather than Tailwind's preflight.
23
24
  */
24
- @layer byline-components {
25
+ @layer byline-components.cms {
25
26
  .byline-richtext-notice {
26
27
  border-radius: var(--border-radius-sm, 4px);
27
28
  font-size: var(--font-size-sm, 0.8125rem);
@@ -1,19 +1,35 @@
1
- .table-modal-container {
2
- min-width: 340px;
3
- max-width: 600px;
4
- }
1
+ @layer base,
2
+ byline-base,
3
+ theme,
4
+ byline-theme,
5
+ byline-functional,
6
+ byline-typography,
7
+ components,
8
+ byline-components,
9
+ overrides,
10
+ byline-utilities,
11
+ utilities;
5
12
 
6
- .table-modal-header {
7
- margin-bottom: 0.5rem;
8
- }
13
+ @layer byline-components.primitives, byline-components.cms;
9
14
 
10
- @media screen and (min-width: 640px) {
11
- .table-modal-select {
12
- margin: 1rem 0 0.5rem;
13
- width: 100%;
15
+ @layer byline-components.cms {
16
+ .table-modal-container {
17
+ min-width: 340px;
18
+ max-width: 600px;
14
19
  }
15
20
 
16
- .table-modal-actions {
17
- margin: 0;
21
+ .table-modal-header {
22
+ margin-bottom: 0.5rem;
23
+ }
24
+
25
+ @media screen and (min-width: 640px) {
26
+ .table-modal-select {
27
+ margin: 1rem 0 0.5rem;
28
+ width: 100%;
29
+ }
30
+
31
+ .table-modal-actions {
32
+ margin: 0;
33
+ }
18
34
  }
19
35
  }