@tiptap/extension-typography 2.0.0-beta.2 → 2.0.0-beta.20

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/LICENSE.md CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2020, überdosis GbR
3
+ Copyright (c) 2021, überdosis GbR
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -7,8 +7,8 @@
7
7
  ## Introduction
8
8
  tiptap is a headless wrapper around [ProseMirror](https://ProseMirror.net) – a toolkit for building rich text WYSIWYG editors, which is already in use at many well-known companies such as *New York Times*, *The Guardian* or *Atlassian*.
9
9
 
10
- ## Offical Documentation
10
+ ## Official Documentation
11
11
  Documentation can be found on the [tiptap website](https://tiptap.dev).
12
12
 
13
13
  ## License
14
- tiptap is open sourced software licensed under the [MIT license](https://github.com/ueberdosis/tiptap-next/blob/main/LICENSE.md).
14
+ tiptap is open sourced software licensed under the [MIT license](https://github.com/ueberdosis/tiptap/blob/main/LICENSE.md).
@@ -1,13 +1,46 @@
1
1
  import { Extension } from '@tiptap/core';
2
- import { InputRule } from 'prosemirror-inputrules';
3
- export declare const leftArrow: InputRule<any>;
4
- export declare const rightArrow: InputRule<any>;
5
- export declare const copyright: InputRule<any>;
6
- export declare const registeredTrademark: InputRule<any>;
7
- export declare const oneHalf: InputRule<any>;
8
- export declare const plusMinus: InputRule<any>;
9
- export declare const notEqual: InputRule<any>;
10
- export declare const laquo: InputRule<any>;
11
- export declare const raquo: InputRule<any>;
12
- export declare const multiplication: InputRule<any>;
13
- export declare const Typography: Extension<unknown>;
2
+ export interface TypographyOptions {
3
+ emDash: false;
4
+ ellipsis: false;
5
+ openDoubleQuote: false;
6
+ closeDoubleQuote: false;
7
+ openSingleQuote: false;
8
+ closeSingleQuote: false;
9
+ leftArrow: false;
10
+ rightArrow: false;
11
+ copyright: false;
12
+ trademark: false;
13
+ registeredTrademark: false;
14
+ oneHalf: false;
15
+ plusMinus: false;
16
+ notEqual: false;
17
+ laquo: false;
18
+ raquo: false;
19
+ multiplication: false;
20
+ superscriptTwo: false;
21
+ superscriptThree: false;
22
+ oneQuarter: false;
23
+ threeQuarters: false;
24
+ }
25
+ export declare const emDash: import("@tiptap/core").InputRule;
26
+ export declare const ellipsis: import("@tiptap/core").InputRule;
27
+ export declare const openDoubleQuote: import("@tiptap/core").InputRule;
28
+ export declare const closeDoubleQuote: import("@tiptap/core").InputRule;
29
+ export declare const openSingleQuote: import("@tiptap/core").InputRule;
30
+ export declare const closeSingleQuote: import("@tiptap/core").InputRule;
31
+ export declare const leftArrow: import("@tiptap/core").InputRule;
32
+ export declare const rightArrow: import("@tiptap/core").InputRule;
33
+ export declare const copyright: import("@tiptap/core").InputRule;
34
+ export declare const trademark: import("@tiptap/core").InputRule;
35
+ export declare const registeredTrademark: import("@tiptap/core").InputRule;
36
+ export declare const oneHalf: import("@tiptap/core").InputRule;
37
+ export declare const plusMinus: import("@tiptap/core").InputRule;
38
+ export declare const notEqual: import("@tiptap/core").InputRule;
39
+ export declare const laquo: import("@tiptap/core").InputRule;
40
+ export declare const raquo: import("@tiptap/core").InputRule;
41
+ export declare const multiplication: import("@tiptap/core").InputRule;
42
+ export declare const superscriptTwo: import("@tiptap/core").InputRule;
43
+ export declare const superscriptThree: import("@tiptap/core").InputRule;
44
+ export declare const oneQuarter: import("@tiptap/core").InputRule;
45
+ export declare const threeQuarters: import("@tiptap/core").InputRule;
46
+ export declare const Typography: Extension<TypographyOptions, any>;
@@ -3,52 +3,183 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var core = require('@tiptap/core');
6
- var prosemirrorInputrules = require('prosemirror-inputrules');
7
6
 
8
- const leftArrow = new prosemirrorInputrules.InputRule(/<-$/, '←');
9
- const rightArrow = new prosemirrorInputrules.InputRule(/->$/, '→');
10
- const copyright = new prosemirrorInputrules.InputRule(/\(c\)$/, '©');
11
- const registeredTrademark = new prosemirrorInputrules.InputRule(/\(r\)$/, '®');
12
- const oneHalf = new prosemirrorInputrules.InputRule(/1\/2$/, '½');
13
- const plusMinus = new prosemirrorInputrules.InputRule(/\+\/-$/, '±');
14
- const notEqual = new prosemirrorInputrules.InputRule(/!=$/, '');
15
- const laquo = new prosemirrorInputrules.InputRule(/<<$/, '«');
16
- const raquo = new prosemirrorInputrules.InputRule(/>>$/, '»');
17
- const multiplication = new prosemirrorInputrules.InputRule(/\d+\s?([*x])\s?\d+$/, '×');
7
+ const emDash = core.textInputRule({
8
+ find: /--$/,
9
+ replace: '',
10
+ });
11
+ const ellipsis = core.textInputRule({
12
+ find: /\.\.\.$/,
13
+ replace: '',
14
+ });
15
+ const openDoubleQuote = core.textInputRule({
16
+ find: /(?:^|[\s{[(<'"\u2018\u201C])(")$/,
17
+ replace: '“',
18
+ });
19
+ const closeDoubleQuote = core.textInputRule({
20
+ find: /"$/,
21
+ replace: '”',
22
+ });
23
+ const openSingleQuote = core.textInputRule({
24
+ find: /(?:^|[\s{[(<'"\u2018\u201C])(')$/,
25
+ replace: '‘',
26
+ });
27
+ const closeSingleQuote = core.textInputRule({
28
+ find: /'$/,
29
+ replace: '’',
30
+ });
31
+ const leftArrow = core.textInputRule({
32
+ find: /<-$/,
33
+ replace: '←',
34
+ });
35
+ const rightArrow = core.textInputRule({
36
+ find: /->$/,
37
+ replace: '→',
38
+ });
39
+ const copyright = core.textInputRule({
40
+ find: /\(c\)$/,
41
+ replace: '©',
42
+ });
43
+ const trademark = core.textInputRule({
44
+ find: /\(tm\)$/,
45
+ replace: '™',
46
+ });
47
+ const registeredTrademark = core.textInputRule({
48
+ find: /\(r\)$/,
49
+ replace: '®',
50
+ });
51
+ const oneHalf = core.textInputRule({
52
+ find: /1\/2$/,
53
+ replace: '½',
54
+ });
55
+ const plusMinus = core.textInputRule({
56
+ find: /\+\/-$/,
57
+ replace: '±',
58
+ });
59
+ const notEqual = core.textInputRule({
60
+ find: /!=$/,
61
+ replace: '≠',
62
+ });
63
+ const laquo = core.textInputRule({
64
+ find: /<<$/,
65
+ replace: '«',
66
+ });
67
+ const raquo = core.textInputRule({
68
+ find: />>$/,
69
+ replace: '»',
70
+ });
71
+ const multiplication = core.textInputRule({
72
+ find: /\d+\s?([*x])\s?\d+$/,
73
+ replace: '×',
74
+ });
75
+ const superscriptTwo = core.textInputRule({
76
+ find: /\^2$/,
77
+ replace: '²',
78
+ });
79
+ const superscriptThree = core.textInputRule({
80
+ find: /\^3$/,
81
+ replace: '³',
82
+ });
83
+ const oneQuarter = core.textInputRule({
84
+ find: /1\/4$/,
85
+ replace: '¼',
86
+ });
87
+ const threeQuarters = core.textInputRule({
88
+ find: /3\/4$/,
89
+ replace: '¾',
90
+ });
18
91
  const Typography = core.Extension.create({
19
92
  name: 'typography',
20
93
  addInputRules() {
21
- return [
22
- prosemirrorInputrules.emDash,
23
- prosemirrorInputrules.ellipsis,
24
- prosemirrorInputrules.openDoubleQuote,
25
- prosemirrorInputrules.closeDoubleQuote,
26
- prosemirrorInputrules.openSingleQuote,
27
- prosemirrorInputrules.closeSingleQuote,
28
- leftArrow,
29
- rightArrow,
30
- copyright,
31
- registeredTrademark,
32
- oneHalf,
33
- plusMinus,
34
- notEqual,
35
- laquo,
36
- raquo,
37
- multiplication,
38
- ];
94
+ const rules = [];
95
+ if (this.options.emDash !== false) {
96
+ rules.push(emDash);
97
+ }
98
+ if (this.options.ellipsis !== false) {
99
+ rules.push(ellipsis);
100
+ }
101
+ if (this.options.openDoubleQuote !== false) {
102
+ rules.push(openDoubleQuote);
103
+ }
104
+ if (this.options.closeDoubleQuote !== false) {
105
+ rules.push(closeDoubleQuote);
106
+ }
107
+ if (this.options.openSingleQuote !== false) {
108
+ rules.push(openSingleQuote);
109
+ }
110
+ if (this.options.closeSingleQuote !== false) {
111
+ rules.push(closeSingleQuote);
112
+ }
113
+ if (this.options.leftArrow !== false) {
114
+ rules.push(leftArrow);
115
+ }
116
+ if (this.options.rightArrow !== false) {
117
+ rules.push(rightArrow);
118
+ }
119
+ if (this.options.copyright !== false) {
120
+ rules.push(copyright);
121
+ }
122
+ if (this.options.trademark !== false) {
123
+ rules.push(trademark);
124
+ }
125
+ if (this.options.registeredTrademark !== false) {
126
+ rules.push(registeredTrademark);
127
+ }
128
+ if (this.options.oneHalf !== false) {
129
+ rules.push(oneHalf);
130
+ }
131
+ if (this.options.plusMinus !== false) {
132
+ rules.push(plusMinus);
133
+ }
134
+ if (this.options.notEqual !== false) {
135
+ rules.push(notEqual);
136
+ }
137
+ if (this.options.laquo !== false) {
138
+ rules.push(laquo);
139
+ }
140
+ if (this.options.raquo !== false) {
141
+ rules.push(raquo);
142
+ }
143
+ if (this.options.multiplication !== false) {
144
+ rules.push(multiplication);
145
+ }
146
+ if (this.options.superscriptTwo !== false) {
147
+ rules.push(superscriptTwo);
148
+ }
149
+ if (this.options.superscriptThree !== false) {
150
+ rules.push(superscriptThree);
151
+ }
152
+ if (this.options.oneQuarter !== false) {
153
+ rules.push(oneQuarter);
154
+ }
155
+ if (this.options.threeQuarters !== false) {
156
+ rules.push(threeQuarters);
157
+ }
158
+ return rules;
39
159
  },
40
160
  });
41
161
 
42
162
  exports.Typography = Typography;
163
+ exports.closeDoubleQuote = closeDoubleQuote;
164
+ exports.closeSingleQuote = closeSingleQuote;
43
165
  exports.copyright = copyright;
44
- exports.default = Typography;
166
+ exports["default"] = Typography;
167
+ exports.ellipsis = ellipsis;
168
+ exports.emDash = emDash;
45
169
  exports.laquo = laquo;
46
170
  exports.leftArrow = leftArrow;
47
171
  exports.multiplication = multiplication;
48
172
  exports.notEqual = notEqual;
49
173
  exports.oneHalf = oneHalf;
174
+ exports.oneQuarter = oneQuarter;
175
+ exports.openDoubleQuote = openDoubleQuote;
176
+ exports.openSingleQuote = openSingleQuote;
50
177
  exports.plusMinus = plusMinus;
51
178
  exports.raquo = raquo;
52
179
  exports.registeredTrademark = registeredTrademark;
53
180
  exports.rightArrow = rightArrow;
181
+ exports.superscriptThree = superscriptThree;
182
+ exports.superscriptTwo = superscriptTwo;
183
+ exports.threeQuarters = threeQuarters;
184
+ exports.trademark = trademark;
54
185
  //# sourceMappingURL=tiptap-extension-typography.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"tiptap-extension-typography.cjs.js","sources":["../src/typography.ts"],"sourcesContent":["import { Extension } from '@tiptap/core'\nimport {\n emDash,\n ellipsis,\n openDoubleQuote,\n closeDoubleQuote,\n openSingleQuote,\n closeSingleQuote,\n InputRule,\n} from 'prosemirror-inputrules'\n\nexport const leftArrow = new InputRule(/<-$/, '←')\nexport const rightArrow = new InputRule(/->$/, '→')\nexport const copyright = new InputRule(/\\(c\\)$/, '©')\nexport const registeredTrademark = new InputRule(/\\(r\\)$/, '®')\nexport const oneHalf = new InputRule(/1\\/2$/, '½')\nexport const plusMinus = new InputRule(/\\+\\/-$/, '±')\nexport const notEqual = new InputRule(/!=$/, '≠')\nexport const laquo = new InputRule(/<<$/, '«')\nexport const raquo = new InputRule(/>>$/, '»')\nexport const multiplication = new InputRule(/\\d+\\s?([*x])\\s?\\d+$/, '×')\n\nexport const Typography = Extension.create({\n name: 'typography',\n\n addInputRules() {\n return [\n emDash,\n ellipsis,\n openDoubleQuote,\n closeDoubleQuote,\n openSingleQuote,\n closeSingleQuote,\n leftArrow,\n rightArrow,\n copyright,\n registeredTrademark,\n oneHalf,\n plusMinus,\n notEqual,\n laquo,\n raquo,\n multiplication,\n ]\n },\n})\n"],"names":["InputRule","Extension","emDash","ellipsis","openDoubleQuote","closeDoubleQuote","openSingleQuote","closeSingleQuote"],"mappings":";;;;;;;MAWa,SAAS,GAAG,IAAIA,+BAAS,CAAC,KAAK,EAAE,GAAG,EAAC;MACrC,UAAU,GAAG,IAAIA,+BAAS,CAAC,KAAK,EAAE,GAAG,EAAC;MACtC,SAAS,GAAG,IAAIA,+BAAS,CAAC,QAAQ,EAAE,GAAG,EAAC;MACxC,mBAAmB,GAAG,IAAIA,+BAAS,CAAC,QAAQ,EAAE,GAAG,EAAC;MAClD,OAAO,GAAG,IAAIA,+BAAS,CAAC,OAAO,EAAE,GAAG,EAAC;MACrC,SAAS,GAAG,IAAIA,+BAAS,CAAC,QAAQ,EAAE,GAAG,EAAC;MACxC,QAAQ,GAAG,IAAIA,+BAAS,CAAC,KAAK,EAAE,GAAG,EAAC;MACpC,KAAK,GAAG,IAAIA,+BAAS,CAAC,KAAK,EAAE,GAAG,EAAC;MACjC,KAAK,GAAG,IAAIA,+BAAS,CAAC,KAAK,EAAE,GAAG,EAAC;MACjC,cAAc,GAAG,IAAIA,+BAAS,CAAC,qBAAqB,EAAE,GAAG,EAAC;MAE1D,UAAU,GAAGC,cAAS,CAAC,MAAM,CAAC;IACzC,IAAI,EAAE,YAAY;IAElB,aAAa;QACX,OAAO;YACLC,4BAAM;YACNC,8BAAQ;YACRC,qCAAe;YACfC,sCAAgB;YAChBC,qCAAe;YACfC,sCAAgB;YAChB,SAAS;YACT,UAAU;YACV,SAAS;YACT,mBAAmB;YACnB,OAAO;YACP,SAAS;YACT,QAAQ;YACR,KAAK;YACL,KAAK;YACL,cAAc;SACf,CAAA;KACF;CACF;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"tiptap-extension-typography.cjs.js","sources":["../src/typography.ts"],"sourcesContent":["import { Extension, textInputRule } from '@tiptap/core'\n\nexport interface TypographyOptions {\n emDash: false,\n ellipsis: false,\n openDoubleQuote: false,\n closeDoubleQuote: false,\n openSingleQuote: false,\n closeSingleQuote: false,\n leftArrow: false,\n rightArrow: false,\n copyright: false,\n trademark: false,\n registeredTrademark: false,\n oneHalf: false,\n plusMinus: false,\n notEqual: false,\n laquo: false,\n raquo: false,\n multiplication: false,\n superscriptTwo: false,\n superscriptThree: false,\n oneQuarter: false,\n threeQuarters: false,\n}\n\nexport const emDash = textInputRule({\n find: /--$/,\n replace: '',\n})\n\nexport const ellipsis = textInputRule({\n find: /\\.\\.\\.$/,\n replace: '…',\n})\n\nexport const openDoubleQuote = textInputRule({\n find: /(?:^|[\\s{[(<'\"\\u2018\\u201C])(\")$/,\n replace: '“',\n})\n\nexport const closeDoubleQuote = textInputRule({\n find: /\"$/,\n replace: '”',\n})\n\nexport const openSingleQuote = textInputRule({\n find: /(?:^|[\\s{[(<'\"\\u2018\\u201C])(')$/,\n replace: '‘',\n})\n\nexport const closeSingleQuote = textInputRule({\n find: /'$/,\n replace: '’',\n})\n\nexport const leftArrow = textInputRule({\n find: /<-$/,\n replace: '←',\n})\n\nexport const rightArrow = textInputRule({\n find: /->$/,\n replace: '→',\n})\n\nexport const copyright = textInputRule({\n find: /\\(c\\)$/,\n replace: '©',\n})\n\nexport const trademark = textInputRule({\n find: /\\(tm\\)$/,\n replace: '™',\n})\n\nexport const registeredTrademark = textInputRule({\n find: /\\(r\\)$/,\n replace: '®',\n})\n\nexport const oneHalf = textInputRule({\n find: /1\\/2$/,\n replace: '½',\n})\n\nexport const plusMinus = textInputRule({\n find: /\\+\\/-$/,\n replace: '±',\n})\n\nexport const notEqual = textInputRule({\n find: /!=$/,\n replace: '≠',\n})\n\nexport const laquo = textInputRule({\n find: /<<$/,\n replace: '«',\n})\n\nexport const raquo = textInputRule({\n find: />>$/,\n replace: '»',\n})\n\nexport const multiplication = textInputRule({\n find: /\\d+\\s?([*x])\\s?\\d+$/,\n replace: '×',\n})\n\nexport const superscriptTwo = textInputRule({\n find: /\\^2$/,\n replace: '²',\n})\n\nexport const superscriptThree = textInputRule({\n find: /\\^3$/,\n replace: '³',\n})\n\nexport const oneQuarter = textInputRule({\n find: /1\\/4$/,\n replace: '¼',\n})\n\nexport const threeQuarters = textInputRule({\n find: /3\\/4$/,\n replace: '¾',\n})\n\nexport const Typography = Extension.create<TypographyOptions>({\n name: 'typography',\n\n addInputRules() {\n const rules = []\n\n if (this.options.emDash !== false) {\n rules.push(emDash)\n }\n\n if (this.options.ellipsis !== false) {\n rules.push(ellipsis)\n }\n\n if (this.options.openDoubleQuote !== false) {\n rules.push(openDoubleQuote)\n }\n\n if (this.options.closeDoubleQuote !== false) {\n rules.push(closeDoubleQuote)\n }\n\n if (this.options.openSingleQuote !== false) {\n rules.push(openSingleQuote)\n }\n\n if (this.options.closeSingleQuote !== false) {\n rules.push(closeSingleQuote)\n }\n\n if (this.options.leftArrow !== false) {\n rules.push(leftArrow)\n }\n\n if (this.options.rightArrow !== false) {\n rules.push(rightArrow)\n }\n\n if (this.options.copyright !== false) {\n rules.push(copyright)\n }\n\n if (this.options.trademark !== false) {\n rules.push(trademark)\n }\n\n if (this.options.registeredTrademark !== false) {\n rules.push(registeredTrademark)\n }\n\n if (this.options.oneHalf !== false) {\n rules.push(oneHalf)\n }\n\n if (this.options.plusMinus !== false) {\n rules.push(plusMinus)\n }\n\n if (this.options.notEqual !== false) {\n rules.push(notEqual)\n }\n\n if (this.options.laquo !== false) {\n rules.push(laquo)\n }\n\n if (this.options.raquo !== false) {\n rules.push(raquo)\n }\n\n if (this.options.multiplication !== false) {\n rules.push(multiplication)\n }\n\n if (this.options.superscriptTwo !== false) {\n rules.push(superscriptTwo)\n }\n\n if (this.options.superscriptThree !== false) {\n rules.push(superscriptThree)\n }\n\n if (this.options.oneQuarter !== false) {\n rules.push(oneQuarter)\n }\n\n if (this.options.threeQuarters !== false) {\n rules.push(threeQuarters)\n }\n\n return rules\n },\n})\n"],"names":["textInputRule","Extension"],"mappings":";;;;;;MA0Ba,MAAM,GAAGA,kBAAa,CAAC;IAClC,IAAI,EAAE,KAAK;IACX,OAAO,EAAE,GAAG;CACb,EAAC;MAEW,QAAQ,GAAGA,kBAAa,CAAC;IACpC,IAAI,EAAE,SAAS;IACf,OAAO,EAAE,GAAG;CACb,EAAC;MAEW,eAAe,GAAGA,kBAAa,CAAC;IAC3C,IAAI,EAAE,kCAAkC;IACxC,OAAO,EAAE,GAAG;CACb,EAAC;MAEW,gBAAgB,GAAGA,kBAAa,CAAC;IAC5C,IAAI,EAAE,IAAI;IACV,OAAO,EAAE,GAAG;C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AK,EAAE;YACzC,KAAK,CAAC,IAAI,CAAC,cAAc,CAAC,CAAA;SAC3B;QAED,IAAI,IAAI,CAAC,OAAO,CAAC,gBAAgB,KAAK,KAAK,EAAE;YAC3C,KAAK,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAA;SAC7B;QAED,IAAI,IAAI,CAAC,OAAO,CAAC,UAAU,KAAK,KAAK,EAAE;YACrC,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,CAAA;SACvB;QAED,IAAI,IAAI,CAAC,OAAO,CAAC,aAAa,KAAK,KAAK,EAAE;YACxC,KAAK,CAAC,IAAI,CAAC,aAAa,CAAC,CAAA;SAC1B;QAED,OAAO,KAAK,CAAA;KACb;CACF;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,40 +1,159 @@
1
- import { Extension } from '@tiptap/core';
2
- import { InputRule, emDash, ellipsis, openDoubleQuote, closeDoubleQuote, openSingleQuote, closeSingleQuote } from 'prosemirror-inputrules';
1
+ import { textInputRule, Extension } from '@tiptap/core';
3
2
 
4
- const leftArrow = new InputRule(/<-$/, '←');
5
- const rightArrow = new InputRule(/->$/, '→');
6
- const copyright = new InputRule(/\(c\)$/, '©');
7
- const registeredTrademark = new InputRule(/\(r\)$/, '®');
8
- const oneHalf = new InputRule(/1\/2$/, '½');
9
- const plusMinus = new InputRule(/\+\/-$/, '±');
10
- const notEqual = new InputRule(/!=$/, '');
11
- const laquo = new InputRule(/<<$/, '«');
12
- const raquo = new InputRule(/>>$/, '»');
13
- const multiplication = new InputRule(/\d+\s?([*x])\s?\d+$/, '×');
3
+ const emDash = textInputRule({
4
+ find: /--$/,
5
+ replace: '',
6
+ });
7
+ const ellipsis = textInputRule({
8
+ find: /\.\.\.$/,
9
+ replace: '',
10
+ });
11
+ const openDoubleQuote = textInputRule({
12
+ find: /(?:^|[\s{[(<'"\u2018\u201C])(")$/,
13
+ replace: '“',
14
+ });
15
+ const closeDoubleQuote = textInputRule({
16
+ find: /"$/,
17
+ replace: '”',
18
+ });
19
+ const openSingleQuote = textInputRule({
20
+ find: /(?:^|[\s{[(<'"\u2018\u201C])(')$/,
21
+ replace: '‘',
22
+ });
23
+ const closeSingleQuote = textInputRule({
24
+ find: /'$/,
25
+ replace: '’',
26
+ });
27
+ const leftArrow = textInputRule({
28
+ find: /<-$/,
29
+ replace: '←',
30
+ });
31
+ const rightArrow = textInputRule({
32
+ find: /->$/,
33
+ replace: '→',
34
+ });
35
+ const copyright = textInputRule({
36
+ find: /\(c\)$/,
37
+ replace: '©',
38
+ });
39
+ const trademark = textInputRule({
40
+ find: /\(tm\)$/,
41
+ replace: '™',
42
+ });
43
+ const registeredTrademark = textInputRule({
44
+ find: /\(r\)$/,
45
+ replace: '®',
46
+ });
47
+ const oneHalf = textInputRule({
48
+ find: /1\/2$/,
49
+ replace: '½',
50
+ });
51
+ const plusMinus = textInputRule({
52
+ find: /\+\/-$/,
53
+ replace: '±',
54
+ });
55
+ const notEqual = textInputRule({
56
+ find: /!=$/,
57
+ replace: '≠',
58
+ });
59
+ const laquo = textInputRule({
60
+ find: /<<$/,
61
+ replace: '«',
62
+ });
63
+ const raquo = textInputRule({
64
+ find: />>$/,
65
+ replace: '»',
66
+ });
67
+ const multiplication = textInputRule({
68
+ find: /\d+\s?([*x])\s?\d+$/,
69
+ replace: '×',
70
+ });
71
+ const superscriptTwo = textInputRule({
72
+ find: /\^2$/,
73
+ replace: '²',
74
+ });
75
+ const superscriptThree = textInputRule({
76
+ find: /\^3$/,
77
+ replace: '³',
78
+ });
79
+ const oneQuarter = textInputRule({
80
+ find: /1\/4$/,
81
+ replace: '¼',
82
+ });
83
+ const threeQuarters = textInputRule({
84
+ find: /3\/4$/,
85
+ replace: '¾',
86
+ });
14
87
  const Typography = Extension.create({
15
88
  name: 'typography',
16
89
  addInputRules() {
17
- return [
18
- emDash,
19
- ellipsis,
20
- openDoubleQuote,
21
- closeDoubleQuote,
22
- openSingleQuote,
23
- closeSingleQuote,
24
- leftArrow,
25
- rightArrow,
26
- copyright,
27
- registeredTrademark,
28
- oneHalf,
29
- plusMinus,
30
- notEqual,
31
- laquo,
32
- raquo,
33
- multiplication,
34
- ];
90
+ const rules = [];
91
+ if (this.options.emDash !== false) {
92
+ rules.push(emDash);
93
+ }
94
+ if (this.options.ellipsis !== false) {
95
+ rules.push(ellipsis);
96
+ }
97
+ if (this.options.openDoubleQuote !== false) {
98
+ rules.push(openDoubleQuote);
99
+ }
100
+ if (this.options.closeDoubleQuote !== false) {
101
+ rules.push(closeDoubleQuote);
102
+ }
103
+ if (this.options.openSingleQuote !== false) {
104
+ rules.push(openSingleQuote);
105
+ }
106
+ if (this.options.closeSingleQuote !== false) {
107
+ rules.push(closeSingleQuote);
108
+ }
109
+ if (this.options.leftArrow !== false) {
110
+ rules.push(leftArrow);
111
+ }
112
+ if (this.options.rightArrow !== false) {
113
+ rules.push(rightArrow);
114
+ }
115
+ if (this.options.copyright !== false) {
116
+ rules.push(copyright);
117
+ }
118
+ if (this.options.trademark !== false) {
119
+ rules.push(trademark);
120
+ }
121
+ if (this.options.registeredTrademark !== false) {
122
+ rules.push(registeredTrademark);
123
+ }
124
+ if (this.options.oneHalf !== false) {
125
+ rules.push(oneHalf);
126
+ }
127
+ if (this.options.plusMinus !== false) {
128
+ rules.push(plusMinus);
129
+ }
130
+ if (this.options.notEqual !== false) {
131
+ rules.push(notEqual);
132
+ }
133
+ if (this.options.laquo !== false) {
134
+ rules.push(laquo);
135
+ }
136
+ if (this.options.raquo !== false) {
137
+ rules.push(raquo);
138
+ }
139
+ if (this.options.multiplication !== false) {
140
+ rules.push(multiplication);
141
+ }
142
+ if (this.options.superscriptTwo !== false) {
143
+ rules.push(superscriptTwo);
144
+ }
145
+ if (this.options.superscriptThree !== false) {
146
+ rules.push(superscriptThree);
147
+ }
148
+ if (this.options.oneQuarter !== false) {
149
+ rules.push(oneQuarter);
150
+ }
151
+ if (this.options.threeQuarters !== false) {
152
+ rules.push(threeQuarters);
153
+ }
154
+ return rules;
35
155
  },
36
156
  });
37
157
 
38
- export default Typography;
39
- export { Typography, copyright, laquo, leftArrow, multiplication, notEqual, oneHalf, plusMinus, raquo, registeredTrademark, rightArrow };
158
+ export { Typography, closeDoubleQuote, closeSingleQuote, copyright, Typography as default, ellipsis, emDash, laquo, leftArrow, multiplication, notEqual, oneHalf, oneQuarter, openDoubleQuote, openSingleQuote, plusMinus, raquo, registeredTrademark, rightArrow, superscriptThree, superscriptTwo, threeQuarters, trademark };
40
159
  //# sourceMappingURL=tiptap-extension-typography.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"tiptap-extension-typography.esm.js","sources":["../src/typography.ts"],"sourcesContent":["import { Extension } from '@tiptap/core'\nimport {\n emDash,\n ellipsis,\n openDoubleQuote,\n closeDoubleQuote,\n openSingleQuote,\n closeSingleQuote,\n InputRule,\n} from 'prosemirror-inputrules'\n\nexport const leftArrow = new InputRule(/<-$/, '←')\nexport const rightArrow = new InputRule(/->$/, '→')\nexport const copyright = new InputRule(/\\(c\\)$/, '©')\nexport const registeredTrademark = new InputRule(/\\(r\\)$/, '®')\nexport const oneHalf = new InputRule(/1\\/2$/, '½')\nexport const plusMinus = new InputRule(/\\+\\/-$/, '±')\nexport const notEqual = new InputRule(/!=$/, '≠')\nexport const laquo = new InputRule(/<<$/, '«')\nexport const raquo = new InputRule(/>>$/, '»')\nexport const multiplication = new InputRule(/\\d+\\s?([*x])\\s?\\d+$/, '×')\n\nexport const Typography = Extension.create({\n name: 'typography',\n\n addInputRules() {\n return [\n emDash,\n ellipsis,\n openDoubleQuote,\n closeDoubleQuote,\n openSingleQuote,\n closeSingleQuote,\n leftArrow,\n rightArrow,\n copyright,\n registeredTrademark,\n oneHalf,\n plusMinus,\n notEqual,\n laquo,\n raquo,\n multiplication,\n ]\n },\n})\n"],"names":[],"mappings":";;;MAWa,SAAS,GAAG,IAAI,SAAS,CAAC,KAAK,EAAE,GAAG,EAAC;MACrC,UAAU,GAAG,IAAI,SAAS,CAAC,KAAK,EAAE,GAAG,EAAC;MACtC,SAAS,GAAG,IAAI,SAAS,CAAC,QAAQ,EAAE,GAAG,EAAC;MACxC,mBAAmB,GAAG,IAAI,SAAS,CAAC,QAAQ,EAAE,GAAG,EAAC;MAClD,OAAO,GAAG,IAAI,SAAS,CAAC,OAAO,EAAE,GAAG,EAAC;MACrC,SAAS,GAAG,IAAI,SAAS,CAAC,QAAQ,EAAE,GAAG,EAAC;MACxC,QAAQ,GAAG,IAAI,SAAS,CAAC,KAAK,EAAE,GAAG,EAAC;MACpC,KAAK,GAAG,IAAI,SAAS,CAAC,KAAK,EAAE,GAAG,EAAC;MACjC,KAAK,GAAG,IAAI,SAAS,CAAC,KAAK,EAAE,GAAG,EAAC;MACjC,cAAc,GAAG,IAAI,SAAS,CAAC,qBAAqB,EAAE,GAAG,EAAC;MAE1D,UAAU,GAAG,SAAS,CAAC,MAAM,CAAC;IACzC,IAAI,EAAE,YAAY;IAElB,aAAa;QACX,OAAO;YACL,MAAM;YACN,QAAQ;YACR,eAAe;YACf,gBAAgB;YAChB,eAAe;YACf,gBAAgB;YAChB,SAAS;YACT,UAAU;YACV,SAAS;YACT,mBAAmB;YACnB,OAAO;YACP,SAAS;YACT,QAAQ;YACR,KAAK;YACL,KAAK;YACL,cAAc;SACf,CAAA;KACF;CACF;;;;;"}
1
+ {"version":3,"file":"tiptap-extension-typography.esm.js","sources":["../src/typography.ts"],"sourcesContent":["import { Extension, textInputRule } from '@tiptap/core'\n\nexport interface TypographyOptions {\n emDash: false,\n ellipsis: false,\n openDoubleQuote: false,\n closeDoubleQuote: false,\n openSingleQuote: false,\n closeSingleQuote: false,\n leftArrow: false,\n rightArrow: false,\n copyright: false,\n trademark: false,\n registeredTrademark: false,\n oneHalf: false,\n plusMinus: false,\n notEqual: false,\n laquo: false,\n raquo: false,\n multiplication: false,\n superscriptTwo: false,\n superscriptThree: false,\n oneQuarter: false,\n threeQuarters: false,\n}\n\nexport const emDash = textInputRule({\n find: /--$/,\n replace: '',\n})\n\nexport const ellipsis = textInputRule({\n find: /\\.\\.\\.$/,\n replace: '…',\n})\n\nexport const openDoubleQuote = textInputRule({\n find: /(?:^|[\\s{[(<'\"\\u2018\\u201C])(\")$/,\n replace: '“',\n})\n\nexport const closeDoubleQuote = textInputRule({\n find: /\"$/,\n replace: '”',\n})\n\nexport const openSingleQuote = textInputRule({\n find: /(?:^|[\\s{[(<'\"\\u2018\\u201C])(')$/,\n replace: '‘',\n})\n\nexport const closeSingleQuote = textInputRule({\n find: /'$/,\n replace: '’',\n})\n\nexport const leftArrow = textInputRule({\n find: /<-$/,\n replace: '←',\n})\n\nexport const rightArrow = textInputRule({\n find: /->$/,\n replace: '→',\n})\n\nexport const copyright = textInputRule({\n find: /\\(c\\)$/,\n replace: '©',\n})\n\nexport const trademark = textInputRule({\n find: /\\(tm\\)$/,\n replace: '™',\n})\n\nexport const registeredTrademark = textInputRule({\n find: /\\(r\\)$/,\n replace: '®',\n})\n\nexport const oneHalf = textInputRule({\n find: /1\\/2$/,\n replace: '½',\n})\n\nexport const plusMinus = textInputRule({\n find: /\\+\\/-$/,\n replace: '±',\n})\n\nexport const notEqual = textInputRule({\n find: /!=$/,\n replace: '≠',\n})\n\nexport const laquo = textInputRule({\n find: /<<$/,\n replace: '«',\n})\n\nexport const raquo = textInputRule({\n find: />>$/,\n replace: '»',\n})\n\nexport const multiplication = textInputRule({\n find: /\\d+\\s?([*x])\\s?\\d+$/,\n replace: '×',\n})\n\nexport const superscriptTwo = textInputRule({\n find: /\\^2$/,\n replace: '²',\n})\n\nexport const superscriptThree = textInputRule({\n find: /\\^3$/,\n replace: '³',\n})\n\nexport const oneQuarter = textInputRule({\n find: /1\\/4$/,\n replace: '¼',\n})\n\nexport const threeQuarters = textInputRule({\n find: /3\\/4$/,\n replace: '¾',\n})\n\nexport const Typography = Extension.create<TypographyOptions>({\n name: 'typography',\n\n addInputRules() {\n const rules = []\n\n if (this.options.emDash !== false) {\n rules.push(emDash)\n }\n\n if (this.options.ellipsis !== false) {\n rules.push(ellipsis)\n }\n\n if (this.options.openDoubleQuote !== false) {\n rules.push(openDoubleQuote)\n }\n\n if (this.options.closeDoubleQuote !== false) {\n rules.push(closeDoubleQuote)\n }\n\n if (this.options.openSingleQuote !== false) {\n rules.push(openSingleQuote)\n }\n\n if (this.options.closeSingleQuote !== false) {\n rules.push(closeSingleQuote)\n }\n\n if (this.options.leftArrow !== false) {\n rules.push(leftArrow)\n }\n\n if (this.options.rightArrow !== false) {\n rules.push(rightArrow)\n }\n\n if (this.options.copyright !== false) {\n rules.push(copyright)\n }\n\n if (this.options.trademark !== false) {\n rules.push(trademark)\n }\n\n if (this.options.registeredTrademark !== false) {\n rules.push(registeredTrademark)\n }\n\n if (this.options.oneHalf !== false) {\n rules.push(oneHalf)\n }\n\n if (this.options.plusMinus !== false) {\n rules.push(plusMinus)\n }\n\n if (this.options.notEqual !== false) {\n rules.push(notEqual)\n }\n\n if (this.options.laquo !== false) {\n rules.push(laquo)\n }\n\n if (this.options.raquo !== false) {\n rules.push(raquo)\n }\n\n if (this.options.multiplication !== false) {\n rules.push(multiplication)\n }\n\n if (this.options.superscriptTwo !== false) {\n rules.push(superscriptTwo)\n }\n\n if (this.options.superscriptThree !== false) {\n rules.push(superscriptThree)\n }\n\n if (this.options.oneQuarter !== false) {\n rules.push(oneQuarter)\n }\n\n if (this.options.threeQuarters !== false) {\n rules.push(threeQuarters)\n }\n\n return rules\n },\n})\n"],"names":[],"mappings":";;MA0Ba,MAAM,GAAG,aAAa,CAAC;IAClC,IAAI,EAAE,KAAK;IACX,OAAO,EAAE,GAAG;CACb,EAAC;MAEW,QAAQ,GAAG,aAAa,CAAC;IACpC,IAAI,EAAE,SAAS;IACf,OAAO,EAAE,GAAG;CACb,EAAC;MAEW,eAAe,GAAG,aAAa,CAAC;IAC3C,IAAI,EAAE,kCAAkC;IACxC,OAAO,EAAE,GAAG;CACb,EAAC;MAEW,gBAAgB,GAAG,aAAa,CAAC;IAC5C,IAAI,EAAE,IAAI;IACV,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