@drghaliasri/butex 3.2.2 → 4.0.1

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/react.d.mts CHANGED
@@ -513,6 +513,24 @@ declare const ATOMIC_OPERATOR_COMMANDS: {
513
513
  readonly title: "أكبر من أو يساوي";
514
514
  readonly svg_path: null;
515
515
  };
516
+ readonly coloneqq: {
517
+ readonly id: "coloneqq";
518
+ readonly category: "operators1";
519
+ readonly Tex: "\\coloneqq";
520
+ readonly mirror: true;
521
+ readonly Label: "≔";
522
+ readonly title: "يعرف بأنه يساوي";
523
+ readonly svg_path: null;
524
+ };
525
+ readonly eqqcolon: {
526
+ readonly id: "eqqcolon";
527
+ readonly category: "operators1";
528
+ readonly Tex: "\\eqqcolon";
529
+ readonly mirror: true;
530
+ readonly Label: "≕";
531
+ readonly title: "يساوي بالتعريف";
532
+ readonly svg_path: null;
533
+ };
516
534
  readonly propto: {
517
535
  readonly id: "propto";
518
536
  readonly category: "operators2";
@@ -676,6 +694,60 @@ declare const ATOMIC_OPERATOR_COMMANDS: {
676
694
  readonly title: "يكافئ";
677
695
  readonly svg_path: null;
678
696
  };
697
+ readonly implies: {
698
+ readonly id: "implies";
699
+ readonly category: "operators3";
700
+ readonly Tex: "\\implies";
701
+ readonly mirror: true;
702
+ readonly Label: "⇒";
703
+ readonly title: "يستلزم";
704
+ readonly svg_path: null;
705
+ };
706
+ readonly impliedby: {
707
+ readonly id: "impliedby";
708
+ readonly category: "operators3";
709
+ readonly Tex: "\\impliedby";
710
+ readonly mirror: true;
711
+ readonly Label: "⇐";
712
+ readonly title: "مستلزم من";
713
+ readonly svg_path: null;
714
+ };
715
+ readonly iff: {
716
+ readonly id: "iff";
717
+ readonly category: "operators3";
718
+ readonly Tex: "\\iff";
719
+ readonly mirror: false;
720
+ readonly Label: "⇔";
721
+ readonly title: "إذا وفقط إذا";
722
+ readonly svg_path: null;
723
+ };
724
+ readonly Longrightarrow: {
725
+ readonly id: "Longrightarrow";
726
+ readonly category: "operators3";
727
+ readonly Tex: "\\Longrightarrow";
728
+ readonly mirror: true;
729
+ readonly Label: "⟹";
730
+ readonly title: "سهم مزدوج طويل إلى اليمين";
731
+ readonly svg_path: null;
732
+ };
733
+ readonly Longleftarrow: {
734
+ readonly id: "Longleftarrow";
735
+ readonly category: "operators3";
736
+ readonly Tex: "\\Longleftarrow";
737
+ readonly mirror: true;
738
+ readonly Label: "⟸";
739
+ readonly title: "سهم مزدوج طويل إلى اليسار";
740
+ readonly svg_path: null;
741
+ };
742
+ readonly to: {
743
+ readonly id: "to";
744
+ readonly category: "operators3";
745
+ readonly Tex: "\\to";
746
+ readonly mirror: true;
747
+ readonly Label: "→";
748
+ readonly title: "يؤول إلى";
749
+ readonly svg_path: null;
750
+ };
679
751
  readonly rightleftharpoons: {
680
752
  readonly id: "rightleftharpoons";
681
753
  readonly category: "operators3";
@@ -823,11 +895,14 @@ declare const ATOMIC_OPERATOR_COMMANDS: {
823
895
  };
824
896
  type AtomicOperatorCommandId = keyof typeof ATOMIC_OPERATOR_COMMANDS;
825
897
 
898
+ type ButexUiLocale = 'ar' | 'en';
899
+
826
900
  type EditorRuntimeApi = {
827
901
  render: () => void;
828
902
  destroy: () => void;
829
903
  getSession: () => EditorSession;
830
904
  setSession: (next: EditorSession) => void;
905
+ setUiLocale: (locale: ButexUiLocale) => void;
831
906
  performUndo: () => void;
832
907
  performRedo: () => void;
833
908
  performCopy: () => Promise<void>;
@@ -884,6 +959,10 @@ type ButexEditorProps = {
884
959
  className?: string;
885
960
  /** Developer panels: LaTeX dump, passive chain preview, debug log. */
886
961
  debug?: boolean;
962
+ /** Initial equation side. Users may still switch sides from the toolbar. */
963
+ defaultSide?: EditorSide;
964
+ /** Human-facing editor chrome language. Independent from the active equation side. */
965
+ uiLocale?: ButexUiLocale;
887
966
  initialSession?: EditorSession;
888
967
  onSessionChange?: (session: EditorSession) => void;
889
968
  };
@@ -892,4 +971,4 @@ type ButexEditorHandle = {
892
971
  };
893
972
  declare const ButexEditor: react.ForwardRefExoticComponent<ButexEditorProps & react.RefAttributes<ButexEditorHandle>>;
894
973
 
895
- export { ButexEditor, type ButexEditorHandle, type ButexEditorProps };
974
+ export { ButexEditor, type ButexEditorHandle, type ButexEditorProps, type ButexUiLocale };
package/dist/react.d.ts CHANGED
@@ -513,6 +513,24 @@ declare const ATOMIC_OPERATOR_COMMANDS: {
513
513
  readonly title: "أكبر من أو يساوي";
514
514
  readonly svg_path: null;
515
515
  };
516
+ readonly coloneqq: {
517
+ readonly id: "coloneqq";
518
+ readonly category: "operators1";
519
+ readonly Tex: "\\coloneqq";
520
+ readonly mirror: true;
521
+ readonly Label: "≔";
522
+ readonly title: "يعرف بأنه يساوي";
523
+ readonly svg_path: null;
524
+ };
525
+ readonly eqqcolon: {
526
+ readonly id: "eqqcolon";
527
+ readonly category: "operators1";
528
+ readonly Tex: "\\eqqcolon";
529
+ readonly mirror: true;
530
+ readonly Label: "≕";
531
+ readonly title: "يساوي بالتعريف";
532
+ readonly svg_path: null;
533
+ };
516
534
  readonly propto: {
517
535
  readonly id: "propto";
518
536
  readonly category: "operators2";
@@ -676,6 +694,60 @@ declare const ATOMIC_OPERATOR_COMMANDS: {
676
694
  readonly title: "يكافئ";
677
695
  readonly svg_path: null;
678
696
  };
697
+ readonly implies: {
698
+ readonly id: "implies";
699
+ readonly category: "operators3";
700
+ readonly Tex: "\\implies";
701
+ readonly mirror: true;
702
+ readonly Label: "⇒";
703
+ readonly title: "يستلزم";
704
+ readonly svg_path: null;
705
+ };
706
+ readonly impliedby: {
707
+ readonly id: "impliedby";
708
+ readonly category: "operators3";
709
+ readonly Tex: "\\impliedby";
710
+ readonly mirror: true;
711
+ readonly Label: "⇐";
712
+ readonly title: "مستلزم من";
713
+ readonly svg_path: null;
714
+ };
715
+ readonly iff: {
716
+ readonly id: "iff";
717
+ readonly category: "operators3";
718
+ readonly Tex: "\\iff";
719
+ readonly mirror: false;
720
+ readonly Label: "⇔";
721
+ readonly title: "إذا وفقط إذا";
722
+ readonly svg_path: null;
723
+ };
724
+ readonly Longrightarrow: {
725
+ readonly id: "Longrightarrow";
726
+ readonly category: "operators3";
727
+ readonly Tex: "\\Longrightarrow";
728
+ readonly mirror: true;
729
+ readonly Label: "⟹";
730
+ readonly title: "سهم مزدوج طويل إلى اليمين";
731
+ readonly svg_path: null;
732
+ };
733
+ readonly Longleftarrow: {
734
+ readonly id: "Longleftarrow";
735
+ readonly category: "operators3";
736
+ readonly Tex: "\\Longleftarrow";
737
+ readonly mirror: true;
738
+ readonly Label: "⟸";
739
+ readonly title: "سهم مزدوج طويل إلى اليسار";
740
+ readonly svg_path: null;
741
+ };
742
+ readonly to: {
743
+ readonly id: "to";
744
+ readonly category: "operators3";
745
+ readonly Tex: "\\to";
746
+ readonly mirror: true;
747
+ readonly Label: "→";
748
+ readonly title: "يؤول إلى";
749
+ readonly svg_path: null;
750
+ };
679
751
  readonly rightleftharpoons: {
680
752
  readonly id: "rightleftharpoons";
681
753
  readonly category: "operators3";
@@ -823,11 +895,14 @@ declare const ATOMIC_OPERATOR_COMMANDS: {
823
895
  };
824
896
  type AtomicOperatorCommandId = keyof typeof ATOMIC_OPERATOR_COMMANDS;
825
897
 
898
+ type ButexUiLocale = 'ar' | 'en';
899
+
826
900
  type EditorRuntimeApi = {
827
901
  render: () => void;
828
902
  destroy: () => void;
829
903
  getSession: () => EditorSession;
830
904
  setSession: (next: EditorSession) => void;
905
+ setUiLocale: (locale: ButexUiLocale) => void;
831
906
  performUndo: () => void;
832
907
  performRedo: () => void;
833
908
  performCopy: () => Promise<void>;
@@ -884,6 +959,10 @@ type ButexEditorProps = {
884
959
  className?: string;
885
960
  /** Developer panels: LaTeX dump, passive chain preview, debug log. */
886
961
  debug?: boolean;
962
+ /** Initial equation side. Users may still switch sides from the toolbar. */
963
+ defaultSide?: EditorSide;
964
+ /** Human-facing editor chrome language. Independent from the active equation side. */
965
+ uiLocale?: ButexUiLocale;
887
966
  initialSession?: EditorSession;
888
967
  onSessionChange?: (session: EditorSession) => void;
889
968
  };
@@ -892,4 +971,4 @@ type ButexEditorHandle = {
892
971
  };
893
972
  declare const ButexEditor: react.ForwardRefExoticComponent<ButexEditorProps & react.RefAttributes<ButexEditorHandle>>;
894
973
 
895
- export { ButexEditor, type ButexEditorHandle, type ButexEditorProps };
974
+ export { ButexEditor, type ButexEditorHandle, type ButexEditorProps, type ButexUiLocale };