@pie-lib/editable-html-tip-tap 2.2.0-beta.9 → 3.0.0-next.20261002094057

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 (235) hide show
  1. package/dist/components/CharacterPicker.d.ts +31 -0
  2. package/dist/components/CharacterPicker.js +141 -0
  3. package/dist/components/EditableHtml.d.ts +11 -0
  4. package/dist/components/EditableHtml.js +331 -0
  5. package/dist/components/MenuBar.d.ts +11 -0
  6. package/dist/components/MenuBar.js +531 -0
  7. package/dist/components/TiptapContainer.d.ts +11 -0
  8. package/dist/components/TiptapContainer.js +167 -0
  9. package/dist/components/characters/characterUtils.d.ts +35 -0
  10. package/dist/components/characters/characterUtils.js +465 -0
  11. package/dist/components/characters/custom-popper.d.ts +14 -0
  12. package/dist/components/characters/custom-popper.js +32 -0
  13. package/dist/components/common/done-button.d.ts +30 -0
  14. package/dist/components/common/done-button.js +26 -0
  15. package/dist/components/common/toolbar-buttons.d.ts +38 -0
  16. package/dist/components/common/toolbar-buttons.js +96 -0
  17. package/dist/components/icons/CssIcon.d.ts +11 -0
  18. package/dist/components/icons/CssIcon.js +14 -0
  19. package/dist/components/icons/RespArea.d.ts +26 -0
  20. package/dist/components/icons/RespArea.js +42 -0
  21. package/dist/components/icons/TableIcons.d.ts +14 -0
  22. package/dist/components/icons/TableIcons.js +34 -0
  23. package/dist/components/icons/TextAlign.d.ts +18 -0
  24. package/dist/components/icons/TextAlign.js +143 -0
  25. package/dist/components/image/AltDialog.d.ts +22 -0
  26. package/dist/components/image/AltDialog.js +61 -0
  27. package/dist/components/image/ImageToolbar.d.ts +24 -0
  28. package/dist/components/image/ImageToolbar.js +80 -0
  29. package/dist/components/image/InsertImageHandler.d.ts +33 -0
  30. package/dist/components/image/InsertImageHandler.js +65 -0
  31. package/dist/components/image/findImageNode.d.ts +3 -0
  32. package/dist/components/image/findImageNode.js +11 -0
  33. package/dist/components/media/MediaDialog.d.ts +43 -0
  34. package/dist/components/media/MediaDialog.js +389 -0
  35. package/dist/components/media/MediaToolbar.d.ts +19 -0
  36. package/dist/components/media/MediaToolbar.js +41 -0
  37. package/dist/components/respArea/DragInTheBlank/DragInTheBlank.d.ts +23 -0
  38. package/dist/components/respArea/DragInTheBlank/DragInTheBlank.js +58 -0
  39. package/dist/components/respArea/DragInTheBlank/choice.d.ts +56 -0
  40. package/dist/components/respArea/DragInTheBlank/choice.js +157 -0
  41. package/dist/components/respArea/ExplicitConstructedResponse.d.ts +20 -0
  42. package/dist/components/respArea/ExplicitConstructedResponse.js +84 -0
  43. package/dist/components/respArea/InlineDropdown.d.ts +18 -0
  44. package/dist/components/respArea/InlineDropdown.js +126 -0
  45. package/dist/components/respArea/MathTemplated.d.ts +19 -0
  46. package/dist/components/respArea/MathTemplated.js +98 -0
  47. package/dist/components/respArea/ToolbarIcon.d.ts +14 -0
  48. package/dist/components/respArea/ToolbarIcon.js +17 -0
  49. package/dist/components/respArea/inlineDropdownUtils.d.ts +15 -0
  50. package/dist/components/respArea/inlineDropdownUtils.js +15 -0
  51. package/dist/constants.d.ts +13 -0
  52. package/dist/constants.js +4 -0
  53. package/dist/extensions/css.d.ts +11 -0
  54. package/dist/extensions/css.js +120 -0
  55. package/dist/extensions/custom-toolbar-wrapper.d.ts +11 -0
  56. package/dist/extensions/custom-toolbar-wrapper.js +61 -0
  57. package/dist/extensions/div-node.d.ts +10 -0
  58. package/dist/extensions/div-node.js +42 -0
  59. package/dist/extensions/ensure-empty-root-div.d.ts +14 -0
  60. package/dist/extensions/ensure-empty-root-div.js +24 -0
  61. package/dist/extensions/ensure-list-item-content-is-div.d.ts +15 -0
  62. package/dist/extensions/ensure-list-item-content-is-div.js +31 -0
  63. package/dist/extensions/extended-list-item.d.ts +13 -0
  64. package/dist/extensions/extended-list-item.js +5 -0
  65. package/dist/extensions/extended-table-cell.d.ts +10 -0
  66. package/dist/extensions/extended-table-cell.js +6 -0
  67. package/dist/extensions/extended-table.d.ts +17 -0
  68. package/dist/extensions/extended-table.js +34 -0
  69. package/dist/extensions/heading-paragraph.d.ts +17 -0
  70. package/dist/extensions/heading-paragraph.js +30 -0
  71. package/dist/extensions/image-component.d.ts +22 -0
  72. package/dist/extensions/image-component.js +223 -0
  73. package/dist/extensions/image.d.ts +10 -0
  74. package/dist/extensions/image.js +77 -0
  75. package/dist/extensions/index.d.ts +16 -0
  76. package/dist/extensions/index.js +64 -0
  77. package/dist/extensions/math.d.ts +15 -0
  78. package/dist/extensions/math.js +214 -0
  79. package/dist/extensions/media.d.ts +19 -0
  80. package/dist/extensions/media.js +149 -0
  81. package/dist/extensions/responseArea.d.ts +27 -0
  82. package/dist/extensions/responseArea.js +255 -0
  83. package/dist/index.d.ts +13 -0
  84. package/dist/index.js +7 -0
  85. package/dist/node_modules/.bun/clsx@2.1.1/node_modules/clsx/dist/clsx.js +16 -0
  86. package/dist/utils/helper.d.ts +9 -0
  87. package/dist/utils/helper.js +27 -0
  88. package/dist/utils/size.d.ts +9 -0
  89. package/dist/utils/size.js +14 -0
  90. package/dist/utils/toolbar.d.ts +10 -0
  91. package/dist/utils/toolbar.js +7 -0
  92. package/package.json +59 -43
  93. package/CHANGELOG.json +0 -32
  94. package/CHANGELOG.md +0 -2532
  95. package/lib/components/CharacterPicker.js +0 -226
  96. package/lib/components/CharacterPicker.js.map +0 -1
  97. package/lib/components/EditableHtml.js +0 -388
  98. package/lib/components/EditableHtml.js.map +0 -1
  99. package/lib/components/MenuBar.js +0 -702
  100. package/lib/components/MenuBar.js.map +0 -1
  101. package/lib/components/TiptapContainer.js +0 -242
  102. package/lib/components/TiptapContainer.js.map +0 -1
  103. package/lib/components/characters/characterUtils.js +0 -378
  104. package/lib/components/characters/characterUtils.js.map +0 -1
  105. package/lib/components/characters/custom-popper.js +0 -44
  106. package/lib/components/characters/custom-popper.js.map +0 -1
  107. package/lib/components/common/done-button.js +0 -34
  108. package/lib/components/common/done-button.js.map +0 -1
  109. package/lib/components/common/toolbar-buttons.js +0 -149
  110. package/lib/components/common/toolbar-buttons.js.map +0 -1
  111. package/lib/components/icons/CssIcon.js +0 -25
  112. package/lib/components/icons/CssIcon.js.map +0 -1
  113. package/lib/components/icons/RespArea.js +0 -72
  114. package/lib/components/icons/RespArea.js.map +0 -1
  115. package/lib/components/icons/TableIcons.js +0 -53
  116. package/lib/components/icons/TableIcons.js.map +0 -1
  117. package/lib/components/icons/TextAlign.js +0 -157
  118. package/lib/components/icons/TextAlign.js.map +0 -1
  119. package/lib/components/image/AltDialog.js +0 -98
  120. package/lib/components/image/AltDialog.js.map +0 -1
  121. package/lib/components/image/ImageToolbar.js +0 -137
  122. package/lib/components/image/ImageToolbar.js.map +0 -1
  123. package/lib/components/image/InsertImageHandler.js +0 -135
  124. package/lib/components/image/InsertImageHandler.js.map +0 -1
  125. package/lib/components/media/MediaDialog.js +0 -594
  126. package/lib/components/media/MediaDialog.js.map +0 -1
  127. package/lib/components/media/MediaToolbar.js +0 -74
  128. package/lib/components/media/MediaToolbar.js.map +0 -1
  129. package/lib/components/media/MediaWrapper.js +0 -67
  130. package/lib/components/media/MediaWrapper.js.map +0 -1
  131. package/lib/components/respArea/DragInTheBlank/DragInTheBlank.js +0 -84
  132. package/lib/components/respArea/DragInTheBlank/DragInTheBlank.js.map +0 -1
  133. package/lib/components/respArea/DragInTheBlank/choice.js +0 -253
  134. package/lib/components/respArea/DragInTheBlank/choice.js.map +0 -1
  135. package/lib/components/respArea/ExplicitConstructedResponse.js +0 -137
  136. package/lib/components/respArea/ExplicitConstructedResponse.js.map +0 -1
  137. package/lib/components/respArea/InlineDropdown.js +0 -223
  138. package/lib/components/respArea/InlineDropdown.js.map +0 -1
  139. package/lib/components/respArea/MathTemplated.js +0 -130
  140. package/lib/components/respArea/MathTemplated.js.map +0 -1
  141. package/lib/components/respArea/ToolbarIcon.js +0 -81
  142. package/lib/components/respArea/ToolbarIcon.js.map +0 -1
  143. package/lib/components/respArea/inlineDropdownUtils.js +0 -67
  144. package/lib/components/respArea/inlineDropdownUtils.js.map +0 -1
  145. package/lib/constants.js +0 -11
  146. package/lib/constants.js.map +0 -1
  147. package/lib/extensions/css.js +0 -227
  148. package/lib/extensions/css.js.map +0 -1
  149. package/lib/extensions/custom-toolbar-wrapper.js +0 -92
  150. package/lib/extensions/custom-toolbar-wrapper.js.map +0 -1
  151. package/lib/extensions/div-node.js +0 -83
  152. package/lib/extensions/div-node.js.map +0 -1
  153. package/lib/extensions/ensure-empty-root-div.js +0 -48
  154. package/lib/extensions/ensure-empty-root-div.js.map +0 -1
  155. package/lib/extensions/ensure-list-item-content-is-div.js +0 -64
  156. package/lib/extensions/ensure-list-item-content-is-div.js.map +0 -1
  157. package/lib/extensions/extended-list-item.js +0 -15
  158. package/lib/extensions/extended-list-item.js.map +0 -1
  159. package/lib/extensions/extended-table-cell.js +0 -22
  160. package/lib/extensions/extended-table-cell.js.map +0 -1
  161. package/lib/extensions/extended-table.js +0 -75
  162. package/lib/extensions/extended-table.js.map +0 -1
  163. package/lib/extensions/heading-paragraph.js +0 -61
  164. package/lib/extensions/heading-paragraph.js.map +0 -1
  165. package/lib/extensions/image-component.js +0 -351
  166. package/lib/extensions/image-component.js.map +0 -1
  167. package/lib/extensions/image.js +0 -134
  168. package/lib/extensions/image.js.map +0 -1
  169. package/lib/extensions/index.js +0 -46
  170. package/lib/extensions/index.js.map +0 -1
  171. package/lib/extensions/math.js +0 -469
  172. package/lib/extensions/math.js.map +0 -1
  173. package/lib/extensions/media.js +0 -243
  174. package/lib/extensions/media.js.map +0 -1
  175. package/lib/extensions/responseArea.js +0 -452
  176. package/lib/extensions/responseArea.js.map +0 -1
  177. package/lib/index.js +0 -37
  178. package/lib/index.js.map +0 -1
  179. package/lib/styles/editorContainerStyles.js +0 -137
  180. package/lib/styles/editorContainerStyles.js.map +0 -1
  181. package/lib/theme.js +0 -8
  182. package/lib/theme.js.map +0 -1
  183. package/lib/utils/helper.js +0 -73
  184. package/lib/utils/helper.js.map +0 -1
  185. package/lib/utils/size.js +0 -26
  186. package/lib/utils/size.js.map +0 -1
  187. package/lib/utils/toolbar.js +0 -19
  188. package/lib/utils/toolbar.js.map +0 -1
  189. package/src/components/CharacterPicker.jsx +0 -237
  190. package/src/components/EditableHtml.jsx +0 -458
  191. package/src/components/MenuBar.jsx +0 -561
  192. package/src/components/TiptapContainer.jsx +0 -235
  193. package/src/components/characters/characterUtils.js +0 -447
  194. package/src/components/characters/custom-popper.js +0 -38
  195. package/src/components/common/done-button.jsx +0 -27
  196. package/src/components/common/toolbar-buttons.jsx +0 -127
  197. package/src/components/icons/CssIcon.jsx +0 -15
  198. package/src/components/icons/RespArea.jsx +0 -71
  199. package/src/components/icons/TableIcons.jsx +0 -52
  200. package/src/components/icons/TextAlign.jsx +0 -114
  201. package/src/components/image/AltDialog.jsx +0 -82
  202. package/src/components/image/ImageToolbar.jsx +0 -99
  203. package/src/components/image/InsertImageHandler.js +0 -107
  204. package/src/components/media/MediaDialog.jsx +0 -596
  205. package/src/components/media/MediaToolbar.jsx +0 -49
  206. package/src/components/media/MediaWrapper.jsx +0 -39
  207. package/src/components/respArea/DragInTheBlank/DragInTheBlank.jsx +0 -76
  208. package/src/components/respArea/DragInTheBlank/choice.jsx +0 -259
  209. package/src/components/respArea/ExplicitConstructedResponse.jsx +0 -136
  210. package/src/components/respArea/InlineDropdown.jsx +0 -240
  211. package/src/components/respArea/MathTemplated.jsx +0 -124
  212. package/src/components/respArea/ToolbarIcon.jsx +0 -66
  213. package/src/components/respArea/inlineDropdownUtils.js +0 -79
  214. package/src/constants.js +0 -5
  215. package/src/extensions/css.js +0 -233
  216. package/src/extensions/custom-toolbar-wrapper.jsx +0 -78
  217. package/src/extensions/div-node.js +0 -86
  218. package/src/extensions/ensure-empty-root-div.js +0 -47
  219. package/src/extensions/ensure-list-item-content-is-div.js +0 -62
  220. package/src/extensions/extended-list-item.js +0 -10
  221. package/src/extensions/extended-table-cell.js +0 -19
  222. package/src/extensions/extended-table.js +0 -60
  223. package/src/extensions/heading-paragraph.js +0 -53
  224. package/src/extensions/image-component.jsx +0 -340
  225. package/src/extensions/image.js +0 -109
  226. package/src/extensions/index.js +0 -81
  227. package/src/extensions/math.js +0 -454
  228. package/src/extensions/media.js +0 -188
  229. package/src/extensions/responseArea.js +0 -407
  230. package/src/index.jsx +0 -5
  231. package/src/styles/editorContainerStyles.js +0 -145
  232. package/src/theme.js +0 -1
  233. package/src/utils/helper.js +0 -69
  234. package/src/utils/size.js +0 -32
  235. package/src/utils/toolbar.js +0 -15
@@ -1,235 +0,0 @@
1
- import React, { useEffect, useMemo, useState, useRef } from 'react';
2
- import { styled } from '@mui/material/styles';
3
- import { color } from '@pie-lib/render-ui';
4
- import { valueToSize } from '../utils/size';
5
-
6
- import StyledMenuBar from './MenuBar';
7
-
8
- const StyledRoot = styled('div', {
9
- shouldForwardProp: (prop) => !['noBorder', 'error'].includes(prop),
10
- })(({ theme, noBorder, error }) => ({
11
- position: 'relative',
12
- padding: '0px',
13
- border: noBorder ? 'none' : '1px solid #ccc',
14
- borderRadius: '4px',
15
- cursor: 'text',
16
- '& [data-slate-editor="true"]': {
17
- wordBreak: 'break-word',
18
- overflow: 'visible',
19
- maxHeight: '500px',
20
- padding: '5px',
21
- },
22
- '&:first-child': {
23
- marginTop: 0,
24
- },
25
- '& ul, & ol': {
26
- padding: '0 1rem',
27
- margin: '1.25rem 1rem 1.25rem 0.4rem',
28
- },
29
- '& ul li p, & ol li p': {
30
- marginTop: '0.25em',
31
- marginBottom: '0.25em',
32
- },
33
- '& h1, & h2, & h3, & h4, & h5, & h6': {
34
- lineHeight: 1.1,
35
- marginTop: '2.5rem',
36
- textWrap: 'pretty',
37
- },
38
- '& h1, & h2': {
39
- marginTop: '3.5rem',
40
- marginBottom: '1.5rem',
41
- },
42
- '& h1': {
43
- fontSize: '1.4rem',
44
- },
45
- '& h2': {
46
- fontSize: '1.2rem',
47
- },
48
- '& h3': {
49
- fontSize: '1.1rem',
50
- },
51
- '& h4, & h5, & h6': {
52
- fontSize: '1rem',
53
- },
54
- '& code': {
55
- backgroundColor: 'var(--purple-light)',
56
- borderRadius: '0.4rem',
57
- color: 'var(--black)',
58
- fontSize: '0.85rem',
59
- padding: '0.25em 0.3em',
60
- },
61
- '& pre': {
62
- background: 'var(--black)',
63
- borderRadius: '0.5rem',
64
- color: 'var(--white)',
65
- fontFamily: '\'JetBrainsMono\', monospace',
66
- margin: '1.5rem 0',
67
- padding: '0.75rem 1rem',
68
- '& code': {
69
- background: 'none',
70
- color: 'inherit',
71
- fontSize: '0.8rem',
72
- padding: 0,
73
- },
74
- },
75
- '& blockquote': {
76
- background: '#f9f9f9',
77
- borderLeft: '5px solid #ccc',
78
- margin: '1.5em 10px',
79
- padding: '.5em 10px',
80
- },
81
- '& p': {
82
- margin: '0',
83
- },
84
- '& table': {
85
- tableLayout: 'fixed',
86
- width: '100%',
87
- borderCollapse: 'collapse',
88
- color: color.text(),
89
- backgroundColor: color.background(),
90
- },
91
- '& table:not([border="1"]) tr': {
92
- borderTop: '1px solid #dfe2e5',
93
- },
94
- '& td, th': {
95
- padding: '.6em 1em',
96
- textAlign: 'center',
97
- },
98
- '& table:not([border="1"]) td, th': {
99
- border: '1px solid #dfe2e5',
100
- },
101
- ...(error && {
102
- border: `2px solid ${theme.palette.error.main} !important`,
103
- }),
104
- }));
105
-
106
- const StyledEditorHolder = styled('div', {
107
- shouldForwardProp: (prop) => !['disableScrollbar', 'highlightShape'].includes(prop),
108
- })(({ theme, disableScrollbar, highlightShape }) => ({
109
- position: 'relative',
110
- padding: '0px',
111
- overflowY: 'auto',
112
- color: color.text(),
113
- backgroundColor: highlightShape ? theme.palette.action.selected : color.background(),
114
- ...(disableScrollbar && {
115
- '&::-webkit-scrollbar': {
116
- display: 'none',
117
- },
118
- scrollbarWidth: 'none',
119
- '-ms-overflow-style': 'none',
120
- }),
121
- }));
122
-
123
- const StyledChildren = styled('div', {
124
- shouldForwardProp: (prop) => prop !== 'noPadding',
125
- })(({ noPadding }) => ({
126
- padding: noPadding ? 0 : '10px 8px',
127
- }));
128
-
129
- function TiptapContainer(props) {
130
- const [adjustedWidth, setAdjustedWidth] = useState(null);
131
- const rootRef = useRef(null);
132
- const {
133
- editor,
134
- disabled,
135
- children,
136
- disableScrollbar,
137
- activePlugins,
138
- toolbarOpts,
139
- responseAreaProps,
140
- autoFocus,
141
- minWidth,
142
- width,
143
- maxWidth,
144
- minHeight,
145
- height,
146
- maxHeight,
147
- highlightShape,
148
- ref,
149
- } = props;
150
-
151
- useEffect(() => {
152
- if (editor && rootRef.current) {
153
- editor._tiptapContainerEl = rootRef.current;
154
- }
155
- }, [editor, rootRef.current]);
156
-
157
- useEffect(() => {
158
- if (editor && autoFocus) {
159
- Promise.resolve().then(() => {
160
- editor.commands.focus('end');
161
- });
162
- }
163
- }, [editor, autoFocus]);
164
-
165
- useEffect(() => {
166
- if (props.adjustWidthForLimit) {
167
- const el = document.createElement('p');
168
-
169
- el.style.visibility = 'hidden';
170
- el.style.position = 'absolute';
171
- el.style.whiteSpace = 'nowrap';
172
- el.textContent = 'W'.repeat(props.charactersLimit);
173
-
174
- // Copy font styles from the editor container so the width measurement reflects the actual font
175
- const computedStyles = window.getComputedStyle(rootRef.current);
176
- const fontStyleProps = [
177
- 'fontFamily',
178
- 'fontSize',
179
- 'fontWeight',
180
- 'fontStyle',
181
- 'letterSpacing',
182
- 'wordSpacing',
183
- 'textTransform',
184
- 'lineHeight',
185
- ];
186
-
187
- fontStyleProps.forEach((prop) => {
188
- el.style[prop] = computedStyles[prop];
189
- });
190
-
191
- document.body.appendChild(el);
192
- setAdjustedWidth(`${el.offsetWidth + 27}px`);
193
- el.remove();
194
- }
195
- }, [props.adjustWidthForLimit, props.charactersLimit]);
196
-
197
- const sizeStyle = useMemo(
198
- () => ({
199
- width: valueToSize(adjustedWidth || width),
200
- minWidth: valueToSize(minWidth),
201
- maxWidth: valueToSize(maxWidth),
202
- height: valueToSize(height),
203
- minHeight: valueToSize(minHeight),
204
- maxHeight: valueToSize(maxHeight),
205
- }),
206
- [adjustedWidth, minWidth, width, maxWidth, minHeight, height, maxHeight],
207
- );
208
-
209
- return (
210
- <StyledRoot
211
- noBorder={toolbarOpts && toolbarOpts.noBorder}
212
- error={toolbarOpts && toolbarOpts.error}
213
- className={props.className}
214
- style={{ width: sizeStyle.width, minWidth: sizeStyle.minWidth, maxWidth: sizeStyle.maxWidth }}
215
- ref={rootRef}
216
- >
217
- <StyledEditorHolder disableScrollbar={disableScrollbar} highlightShape={highlightShape}>
218
- <StyledChildren noPadding={toolbarOpts && toolbarOpts.noPadding}>{children}</StyledChildren>
219
- </StyledEditorHolder>
220
-
221
- {editor && (
222
- <StyledMenuBar
223
- editor={editor}
224
- responseAreaProps={responseAreaProps}
225
- toolbarOpts={toolbarOpts}
226
- activePlugins={activePlugins}
227
- onChange={props.onChange}
228
- autoWidthToolbar={props.autoWidthToolbar}
229
- />
230
- )}
231
- </StyledRoot>
232
- );
233
- }
234
-
235
- export default TiptapContainer;
@@ -1,447 +0,0 @@
1
- export const spanishConfig = {
2
- characters: [
3
- ['á', 'é', 'í', 'ó', 'ú'],
4
- ['Á', 'É', 'Í', 'Ó', 'Ú'],
5
- ['—', '«', '»', 'ñ', 'ü'],
6
- ['-', '¿', '¡', 'Ñ', 'Ü'],
7
- ],
8
- };
9
-
10
- export const specialConfig = {
11
- hasPreview: true,
12
- characters: [
13
- [
14
- {
15
- unicode: 'U+00A2',
16
- description: 'CENT SIGN',
17
- write: '¢',
18
- label: '¢',
19
- },
20
- {
21
- unicode: 'U+00BF',
22
- description: 'INVERTED QUESTION MARK',
23
- write: '¿',
24
- label: '¿',
25
- },
26
- {
27
- unicode: 'U+00B4',
28
- description: 'ACUTE ACCENT',
29
- write: '´',
30
- label: '´',
31
- extraProps: { style: { gridRow: 'span 2' } },
32
- },
33
- {
34
- unicode: 'U+00E1',
35
- description: 'LATIN SMALL LETTER A WITH ACUTE',
36
- write: 'á',
37
- label: 'á',
38
- },
39
- {
40
- unicode: 'U+00E9',
41
- description: 'LATIN SMALL LETTER E WITH ACUTE',
42
- write: 'é',
43
- label: 'é',
44
- },
45
- {
46
- unicode: 'U+00ED',
47
- description: 'LATIN SMALL LETTER I WITH ACUTE',
48
- write: 'í',
49
- label: 'í',
50
- },
51
- {
52
- unicode: 'U+00F3',
53
- description: 'LATIN SMALL LETTER O WITH ACUTE',
54
- write: 'ó',
55
- label: 'ó',
56
- },
57
- {
58
- unicode: 'U+00FA',
59
- description: 'LATIN SMALL LETTER U WITH ACUTE',
60
- write: 'ú',
61
- label: 'ú',
62
- },
63
- {
64
- unicode: 'U+00F1',
65
- description: 'LATIN SMALL LETTER N WITH TILDE',
66
- write: 'ñ',
67
- label: 'ñ',
68
- },
69
- ],
70
- [
71
- {
72
- unicode: 'U+20AC',
73
- description: 'EURO SIGN',
74
- write: '€',
75
- label: '€',
76
- },
77
- {
78
- unicode: 'U+00A1',
79
- description: 'INVERTED EXCLAMATION MARK',
80
- write: '¡',
81
- label: '¡',
82
- },
83
- {
84
- unicode: 'U+00C1',
85
- description: 'LATIN CAPITAL LETTER A WITH ACUTE',
86
- write: 'Á',
87
- label: 'Á',
88
- },
89
- {
90
- unicode: 'U+00C9',
91
- description: 'LATIN CAPITAL LETTER E WITH ACUTE',
92
- write: 'É',
93
- label: 'É',
94
- },
95
- {
96
- unicode: 'U+00CD',
97
- description: 'LATIN CAPITAL LETTER I WITH ACUTE',
98
- write: 'Í',
99
- label: 'Í',
100
- },
101
- {
102
- unicode: 'U+00D3',
103
- description: 'LATIN CAPITAL LETTER O WITH ACUTE',
104
- write: 'Ó',
105
- label: 'Ó',
106
- },
107
- {
108
- unicode: 'U+00DA',
109
- description: 'LATIN CAPITAL LETTER U WITH ACUTE',
110
- write: 'Ú',
111
- label: 'Ú',
112
- },
113
- {
114
- unicode: 'U+00D1',
115
- description: 'LATIN CAPITAL LETTER N WITH TILDE',
116
- write: 'Ñ',
117
- label: 'Ñ',
118
- },
119
- ],
120
- [
121
- {
122
- unicode: 'U+00A3',
123
- description: 'POUND SIGN',
124
- write: '£',
125
- label: '£',
126
- },
127
- {
128
- unicode: 'U+00AB',
129
- description: 'LEFT-POINTING DOUBLE ANGLE QUOTATION MARK',
130
- write: '«',
131
- label: '«',
132
- },
133
- {
134
- unicode: 'U+005E',
135
- description: 'CIRCUMFLEX ACCENT',
136
- write: '^',
137
- label: '^',
138
- extraProps: { style: { gridRow: 'span 2' } },
139
- },
140
- {
141
- unicode: 'U+00E2',
142
- description: 'LATIN SMALL LETTER A WITH CIRCUMFLEX',
143
- write: 'â',
144
- label: 'â',
145
- },
146
- {
147
- unicode: 'U+00EA',
148
- description: 'LATIN SMALL LETTER E WITH CIRCUMFLEX',
149
- write: 'ê',
150
- label: 'ê',
151
- },
152
- {
153
- unicode: 'U+00EE',
154
- description: 'LATIN SMALL LETTER I WITH CIRCUMFLEX',
155
- write: 'î',
156
- label: 'î',
157
- },
158
- {
159
- unicode: 'U+00F4',
160
- description: 'LATIN SMALL LETTER O WITH CIRCUMFLEX',
161
- write: 'ô',
162
- label: 'ô',
163
- },
164
- {
165
- unicode: 'U+00FB',
166
- description: 'LATIN SMALL LETTER U WITH CIRCUMFLEX',
167
- write: 'û',
168
- label: 'û',
169
- },
170
- {
171
- unicode: 'U+00E7',
172
- description: 'LATIN SMALL LETTER C WITH CEDILLA',
173
- write: 'ç',
174
- label: 'ç',
175
- },
176
- ],
177
- [
178
- {
179
- unicode: 'U+00A5',
180
- description: 'YEN SIGN',
181
- write: '¥',
182
- label: '¥',
183
- },
184
- {
185
- unicode: 'U+00BB',
186
- description: 'RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK',
187
- write: '»',
188
- label: '»',
189
- },
190
- {
191
- unicode: 'U+00C2',
192
- description: 'LATIN CAPITAL LETTER A WITH CIRCUMFLEX',
193
- write: 'Â',
194
- label: 'Â',
195
- },
196
- {
197
- unicode: 'U+00CA',
198
- description: 'LATIN CAPITAL LETTER E WITH CIRCUMFLEX',
199
- write: 'Ê',
200
- label: 'Ê',
201
- },
202
- {
203
- unicode: 'U+00CE',
204
- description: 'LATIN CAPITAL LETTER I WITH CIRCUMFLEX',
205
- write: 'Î',
206
- label: 'Î',
207
- },
208
- {
209
- unicode: 'U+00D4',
210
- description: 'LATIN CAPITAL LETTER O WITH CIRCUMFLEX',
211
- write: 'Ô',
212
- label: 'Ô',
213
- },
214
- {
215
- unicode: 'U+00DB',
216
- description: 'LATIN CAPITAL LETTER U WITH CIRCUMFLEX',
217
- write: 'Û',
218
- label: 'Û',
219
- },
220
- {
221
- unicode: 'U+00C7',
222
- description: 'LATIN CAPITAL LETTER C WITH CEDILLA',
223
- write: 'Ç',
224
- label: 'Ç',
225
- },
226
- ],
227
- [
228
- {
229
- unicode: 'U+200A',
230
- description: 'HAIR SPACE',
231
- write: String.fromCodePoint('0x200A'),
232
- label: '&hairsp;',
233
- },
234
- {
235
- unicode: 'U+00A7',
236
- description: 'SECTION SIGN',
237
- write: '§',
238
- label: '§',
239
- },
240
- {
241
- unicode: 'U+00A8',
242
- description: 'DIAERESIS',
243
- write: '¨',
244
- label: '¨',
245
- extraProps: { style: { gridRow: 'span 2' } },
246
- },
247
- {
248
- unicode: 'U+00E4',
249
- description: 'LATIN SMALL LETTER A WITH DIAERESIS',
250
- write: 'ä',
251
- label: 'ä',
252
- },
253
- {
254
- unicode: 'U+00EB',
255
- description: 'LATIN SMALL LETTER E WITH DIAERESIS',
256
- write: 'ë',
257
- label: 'ë',
258
- },
259
- {
260
- unicode: 'U+00EF',
261
- description: 'LATIN SMALL LETTER I WITH DIAERESIS',
262
- write: 'ï',
263
- label: 'ï',
264
- },
265
- {
266
- unicode: 'U+00F6',
267
- description: 'LATIN SMALL LETTER O WITH DIAERESIS',
268
- write: 'ö',
269
- label: 'ö',
270
- },
271
- {
272
- unicode: 'U+00FC',
273
- description: 'LATIN SMALL LETTER U WITH DIAERESIS',
274
- write: 'ü',
275
- label: 'ü',
276
- },
277
- {
278
- unicode: 'U+00DF',
279
- description: 'LATIN SMALL LETTER SHARP S',
280
- write: 'ß',
281
- label: 'ß',
282
- },
283
- ],
284
- [
285
- {
286
- unicode: 'U+2009',
287
- description: 'THIN SPACE',
288
- write: String.fromCodePoint('0x2009'),
289
- label: '&thinsp;',
290
- },
291
- {
292
- unicode: 'U+2026',
293
- description: 'HORIZONTAL ELLIPSIS',
294
- write: '…',
295
- label: '…',
296
- },
297
- {
298
- unicode: 'U+00C4',
299
- description: 'LATIN CAPITAL LETTER A WITH DIAERESIS',
300
- write: 'Ä',
301
- label: 'Ä',
302
- },
303
- {
304
- unicode: 'U+00CB',
305
- description: 'LATIN CAPITAL LETTER E WITH DIAERESIS',
306
- write: 'Ë',
307
- label: 'Ë',
308
- },
309
- {
310
- unicode: 'U+00CF',
311
- description: 'LATIN CAPITAL LETTER I WITH DIAERESIS',
312
- write: 'Ï',
313
- label: 'Ï',
314
- },
315
- {
316
- unicode: 'U+00D6',
317
- description: 'LATIN CAPITAL LETTER O WITH DIAERESIS',
318
- write: 'Ö',
319
- label: 'Ö',
320
- },
321
- {
322
- unicode: 'U+00DC',
323
- description: 'LATIN CAPITAL LETTER U WITH DIAERESIS',
324
- write: 'Ü',
325
- label: 'Ü',
326
- },
327
- {
328
- unicode: 'U+2212',
329
- description: 'MINUS SIGN',
330
- write: '−',
331
- label: '−',
332
- },
333
- ],
334
- [
335
- {
336
- unicode: 'U+00A0',
337
- description: 'NO-BREAK SPACE',
338
- write: String.fromCodePoint('0x00A0'),
339
- label: '&nbsp;',
340
- },
341
- {
342
- unicode: 'U+2022',
343
- description: 'BULLET',
344
- write: '•',
345
- label: '•',
346
- },
347
- {
348
- unicode: 'U+0060',
349
- description: 'GRAVE ACCENT',
350
- write: '`',
351
- label: '`',
352
- extraProps: { style: { gridRow: 'span 2' } },
353
- },
354
- {
355
- unicode: 'U+00E0',
356
- description: 'LATIN SMALL LETTER A WITH GRAVE',
357
- write: 'à',
358
- label: 'à',
359
- },
360
- {
361
- unicode: 'U+00E8',
362
- description: 'LATIN SMALL LETTER E WITH GRAVE',
363
- write: 'è',
364
- label: 'è',
365
- },
366
- {
367
- unicode: 'U+00EC',
368
- description: 'LATIN SMALL LETTER I WITH GRAVE',
369
- write: 'ì',
370
- label: 'ì',
371
- },
372
- {
373
- unicode: 'U+00F2',
374
- description: 'LATIN SMALL LETTER O WITH GRAVE',
375
- write: 'ò',
376
- label: 'ò',
377
- },
378
- {
379
- unicode: 'U+00F9',
380
- description: 'LATIN SMALL LETTER U WITH GRAVE',
381
- write: 'ù',
382
- label: 'ù',
383
- },
384
- {
385
- unicode: 'U+2013',
386
- description: 'EN DASH',
387
- write: '–',
388
- label: '–',
389
- },
390
- ],
391
- [
392
- {
393
- unicode: 'U+2003',
394
- description: 'EM SPACE',
395
- write: String.fromCodePoint('0x2003'),
396
- label: '&emsp;',
397
- },
398
- {
399
- unicode: 'U+25E6',
400
- description: 'WHITE BULLET',
401
- write: '◦',
402
- label: '◦',
403
- },
404
- {
405
- unicode: 'U+00C0',
406
- description: 'LATIN CAPITAL LETTER A WITH GRAVE',
407
- write: 'À',
408
- label: 'À',
409
- },
410
- {
411
- unicode: 'U+00C8',
412
- description: 'LATIN CAPITAL LETTER E WITH GRAVE',
413
- write: 'È',
414
- label: 'È',
415
- },
416
- {
417
- unicode: 'U+00CC',
418
- description: 'LATIN CAPITAL LETTER I WITH GRAVE',
419
- write: 'Ì',
420
- label: 'Ì',
421
- },
422
- {
423
- unicode: 'U+00D2',
424
- description: 'LATIN CAPITAL LETTER O WITH GRAVE',
425
- write: 'Ò',
426
- label: 'Ò',
427
- },
428
- {
429
- unicode: 'U+00D9',
430
- description: 'LATIN CAPITAL LETTER U WITH GRAVE',
431
- write: 'Ù',
432
- label: 'Ù',
433
- },
434
- {
435
- unicode: 'U+2014',
436
- description: 'EM DASH',
437
- write: '—',
438
- label: '—',
439
- },
440
- ],
441
- ],
442
- };
443
-
444
- export const characterIcons = {
445
- spanish: 'ñ',
446
- special: '€',
447
- };
@@ -1,38 +0,0 @@
1
- import React from 'react';
2
- import { styled } from '@mui/material/styles';
3
- import Popper from '@mui/material/Popper';
4
- import Typography from '@mui/material/Typography';
5
-
6
- const StyledPopper = styled(Popper)({
7
- background: '#fff',
8
- padding: '10px',
9
- pointerEvents: 'none',
10
- zIndex: 99999,
11
- });
12
-
13
- const StyledTypography = styled(Typography)({
14
- fontSize: 50,
15
- textAlign: 'center',
16
- });
17
-
18
- const CustomPopper = ({ children, ...props }) => (
19
- <StyledPopper
20
- id="mouse-over-popover"
21
- open
22
- anchorOrigin={{
23
- vertical: 'bottom',
24
- horizontal: 'left',
25
- }}
26
- transformOrigin={{
27
- vertical: 'top',
28
- horizontal: 'left',
29
- }}
30
- disableRestoreFocus
31
- disableAutoFocus
32
- {...props}
33
- >
34
- <StyledTypography>{children}</StyledTypography>
35
- </StyledPopper>
36
- );
37
-
38
- export default CustomPopper;