@doenet/doenetml-iframe 0.7.21-dev.416 → 0.7.21-dev.417

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 (4) hide show
  1. package/index.js +14 -6
  2. package/index.js.map +1 -1
  3. package/package.json +1 -1
  4. package/style.css +154 -132
package/index.js CHANGED
@@ -40841,7 +40841,8 @@ const KeyboardIcon = () => /* @__PURE__ */ React__default.createElement(
40841
40841
  function KeyboardTray({
40842
40842
  onClick,
40843
40843
  theme,
40844
- translate
40844
+ translate,
40845
+ direction
40845
40846
  }) {
40846
40847
  const [open, setOpen] = React__default.useState(false);
40847
40848
  const t4 = translate ?? untranslated;
@@ -40853,6 +40854,7 @@ function KeyboardTray({
40853
40854
  {
40854
40855
  id: "virtual-keyboard-tray",
40855
40856
  "data-theme": theme,
40857
+ dir: direction,
40856
40858
  className: classNames({ open }),
40857
40859
  onMouseDown: () => {
40858
40860
  onClick([
@@ -67206,24 +67208,27 @@ function rerenderTray() {
67206
67208
  const registration = getTrayRegistration();
67207
67209
  const theme = registration?.theme;
67208
67210
  const translate = registration?.translate;
67211
+ const direction = registration?.direction;
67209
67212
  const trayEl = getTrayElement();
67210
67213
  if (trayEl) {
67211
67214
  const currentTheme = trayEl.getAttribute("data-theme") ?? void 0;
67212
- if (currentTheme === theme && virtualKeyboardState.lastRenderedTranslate === translate) {
67215
+ const currentDirection = trayEl.getAttribute("dir") ?? void 0;
67216
+ if (currentTheme === theme && currentDirection === direction && virtualKeyboardState.lastRenderedTranslate === translate) {
67213
67217
  return;
67214
67218
  }
67215
67219
  }
67216
67220
  virtualKeyboardState.lastRenderedTranslate = translate;
67217
67221
  virtualKeyboardState.keyboardReactRoot?.render(
67218
- renderTray(theme, translate)
67222
+ renderTray(theme, translate, direction)
67219
67223
  );
67220
67224
  }
67221
- function renderTray(theme, translate) {
67225
+ function renderTray(theme, translate, direction) {
67222
67226
  return /* @__PURE__ */ React__default.createElement(MathJaxContext, { config: mathjaxConfig, version: 4 }, /* @__PURE__ */ React__default.createElement(
67223
67227
  KeyboardTray,
67224
67228
  {
67225
67229
  theme,
67226
67230
  translate,
67231
+ direction,
67227
67232
  onClick: (e2) => {
67228
67233
  getActiveRegistration()?.onClick(e2);
67229
67234
  }
@@ -67233,6 +67238,7 @@ function renderTray(theme, translate) {
67233
67238
  function UniqueKeyboardTray({
67234
67239
  onClick,
67235
67240
  theme,
67241
+ direction,
67236
67242
  translate,
67237
67243
  ownerRef
67238
67244
  }) {
@@ -67263,6 +67269,7 @@ function UniqueKeyboardTray({
67263
67269
  onClick,
67264
67270
  theme,
67265
67271
  translate,
67272
+ direction,
67266
67273
  ownerRef
67267
67274
  });
67268
67275
  rerenderTray();
@@ -67307,10 +67314,11 @@ function UniqueKeyboardTray({
67307
67314
  registration.onClick = onClick;
67308
67315
  registration.theme = theme;
67309
67316
  registration.translate = translate;
67317
+ registration.direction = direction;
67310
67318
  registration.ownerRef = ownerRef;
67311
67319
  rerenderTray();
67312
67320
  }
67313
- }, [onClick, ownerRef, theme, translate]);
67321
+ }, [onClick, ownerRef, theme, translate, direction]);
67314
67322
  return null;
67315
67323
  }
67316
67324
  function ExternalVirtualKeyboard({
@@ -67342,7 +67350,7 @@ function ExternalVirtualKeyboard({
67342
67350
  }
67343
67351
  );
67344
67352
  }
67345
- const version = "0.7.21-dev.416";
67353
+ const version = "0.7.21-dev.417";
67346
67354
  const latestDoenetmlVersion = version;
67347
67355
  function subscribeToPinnedTheme() {
67348
67356
  return () => {