pixel-react 1.14.40 → 1.14.42
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/lib/_virtual/index4.js +3 -5
- package/lib/_virtual/index4.js.map +1 -1
- package/lib/_virtual/index5.js +5 -3
- package/lib/_virtual/index5.js.map +1 -1
- package/lib/assets/icons/windows.svg.js +1 -1
- package/lib/assets/icons/windows.svg.js.map +1 -1
- package/lib/components/Comments/Comments.js +1 -1
- package/lib/components/Comments/Comments.js.map +1 -1
- package/lib/components/Excel/Data.d.ts +127 -0
- package/lib/components/Excel/Data.js +646 -0
- package/lib/components/Excel/Data.js.map +1 -0
- package/lib/components/Excel/Data2.d.ts +133 -0
- package/lib/components/Excel/Data2.js +698 -0
- package/lib/components/Excel/Data2.js.map +1 -0
- package/lib/components/Excel/ExcelContextMenu/ExcelContextMenu.d.ts +0 -1
- package/lib/components/Excel/ExcelContextMenu/ExcelContextMenu.js +3 -6
- package/lib/components/Excel/ExcelContextMenu/ExcelContextMenu.js.map +1 -1
- package/lib/components/Excel/ExcelFile/ExcelFile.d.ts +8 -20
- package/lib/components/Excel/ExcelFile/ExcelFile.js +37 -31
- package/lib/components/Excel/ExcelFile/ExcelFile.js.map +1 -1
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/ActiveCell.d.ts +1 -12
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/ActiveCell.js +1 -0
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/ActiveCell.js.map +1 -1
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/ColumnIndicator.js +13 -9
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/ColumnIndicator.js.map +1 -1
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/RowIndicator.js +14 -10
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/RowIndicator.js.map +1 -1
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/Spreadsheet.d.ts +3 -12
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/Spreadsheet.js +17 -5
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/Spreadsheet.js.map +1 -1
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/actions.d.ts +19 -12
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/actions.js +18 -12
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/actions.js.map +1 -1
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/reducer.js +39 -21
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/reducer.js.map +1 -1
- package/lib/components/Excel/ExcelFile/ExcelFileComponents/types.d.ts +11 -6
- package/lib/components/Excel/Types.d.ts +1 -0
- package/lib/components/MultiSelect/MultiSelect.js +1 -1
- package/lib/components/MultiSelect/MultiSelect.js.map +1 -1
- package/lib/components/Select/Select.js +2 -1
- package/lib/components/Select/Select.js.map +1 -1
- package/lib/components/Table/Table.js +1 -1
- package/lib/components/Table/Table.js.map +1 -1
- package/lib/index.cjs +148 -99
- package/lib/index.cjs.map +1 -1
- package/lib/index.d.ts +29 -27
- package/lib/node_modules/input-format/modules/react/Input.js +1 -1
- package/lib/node_modules/js-beautify/js/src/css/beautifier.js +1 -1
- package/lib/node_modules/js-beautify/js/src/css/options.js +1 -1
- package/lib/node_modules/js-beautify/js/src/html/beautifier.js +1 -1
- package/lib/node_modules/js-beautify/js/src/html/options.js +1 -1
- package/lib/node_modules/js-beautify/js/src/html/tokenizer.js +1 -1
- package/lib/node_modules/js-beautify/js/src/javascript/tokenizer.js +1 -1
- package/lib/node_modules/react-google-recaptcha/lib/esm/recaptcha.js +1 -1
- package/lib/node_modules/react-phone-number-input/modules/CountryIcon.js +1 -1
- package/lib/node_modules/react-phone-number-input/modules/CountrySelect.js +1 -1
- package/lib/node_modules/react-phone-number-input/modules/Flag.js +1 -1
- package/lib/node_modules/react-phone-number-input/modules/InputBasic.js +1 -1
- package/lib/node_modules/react-phone-number-input/modules/InputSmart.js +1 -1
- package/lib/node_modules/react-phone-number-input/modules/InternationalIcon.js +1 -1
- package/lib/node_modules/react-phone-number-input/modules/PhoneInputWithCountry.js +1 -1
- package/lib/node_modules/react-phone-number-input/modules/PhoneInputWithCountryDefault.js +1 -1
- package/lib/node_modules/react-phone-number-input/modules/PropTypes.js +1 -1
- package/lib/node_modules/use-context-selector/dist/index.js +1 -1
- package/lib/styles.css +1 -1
- package/lib/styles.css.map +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
package/lib/index.cjs
CHANGED
@@ -392,7 +392,7 @@ const SvgLicenseWarning = (props) => /* @__PURE__ */ React__namespace.createElem
|
|
392
392
|
|
393
393
|
const SvgVariableIcon = (props) => /* @__PURE__ */ React__namespace.createElement("svg", { width: "1em", height: "1em", viewBox: "0 0 15 15", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props }, /* @__PURE__ */ React__namespace.createElement("path", { d: "M10.5 4.5L8.40169 10.5H6.59831L4.5 4.5H6.03371L7.5 9.02991L8.97472 4.5H10.5Z", fill: "currentColor" }), /* @__PURE__ */ React__namespace.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M1.28395 1.28395C2.21109 0.356801 3.60069 0 5.4 0H9.6C11.3993 0 12.7889 0.356801 13.7161 1.28395C14.6432 2.21109 15 3.60069 15 5.4V9.6C15 11.3993 14.6432 12.7889 13.7161 13.7161C12.7889 14.6432 11.3993 15 9.6 15H5.4C3.60069 15 2.21109 14.6432 1.28395 13.7161C0.356801 12.7889 0 11.3993 0 9.6V5.4C0 3.60069 0.356801 2.21109 1.28395 1.28395ZM1.99105 1.99105C1.3432 2.63891 1 3.69931 1 5.4V9.6C1 11.3007 1.3432 12.3611 1.99105 13.0089C2.63891 13.6568 3.69931 14 5.4 14H9.6C11.3007 14 12.3611 13.6568 13.0089 13.0089C13.6568 12.3611 14 11.3007 14 9.6V5.4C14 3.69931 13.6568 2.63891 13.0089 1.99105C12.3611 1.3432 11.3007 1 9.6 1H5.4C3.69931 1 2.63891 1.3432 1.99105 1.99105Z", fill: "currentColor" }));
|
394
394
|
|
395
|
-
const SvgWindows = (props) => /* @__PURE__ */ React__namespace.createElement("svg", { width: "1em", height: "1em", viewBox: "0 0 12 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props }, /* @__PURE__ */ React__namespace.createElement("path", { d: "M4.80888 12.0185L0.114433 11.3751L0.00422248 11.36L0.00421445 11.2489L0.00396729 7.39195V7.26428H0.131141H4.82583H4.95351V7.39195V11.8924V12.0384L4.80888 12.0185Z", fill: "
|
395
|
+
const SvgWindows = (props) => /* @__PURE__ */ React__namespace.createElement("svg", { width: "1em", height: "1em", viewBox: "0 0 12 14", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props }, /* @__PURE__ */ React__namespace.createElement("path", { d: "M4.80888 12.0185L0.114433 11.3751L0.00422248 11.36L0.00421445 11.2489L0.00396729 7.39195V7.26428H0.131141H4.82583H4.95351V7.39195V11.8924V12.0384L4.80888 12.0185Z", fill: "#00BCD4" }), /* @__PURE__ */ React__namespace.createElement("path", { d: "M12.0003 7.39195L11.9987 12.8732V13.0197L11.8541 12.9993L5.59136 12.1182L5.48114 12.1028V11.9921V7.39195V7.26428H5.60882H11.8731H12.0003V7.39195Z", fill: "#00BCD4" }), /* @__PURE__ */ React__namespace.createElement("path", { d: "M5.59086 1.91281L11.8536 1.00154L11.9993 0.980347V1.12771V6.60891V6.73658H11.8715H5.60882H5.48114V6.60891V2.03899V1.92879L5.59086 1.91281Z", fill: "#00BCD4" }), /* @__PURE__ */ React__namespace.createElement("path", { d: "M0.00418431 6.60893L-0.000124334 2.79077L-0.000244141 2.67959L0.110094 2.6646L4.80836 2.02659L4.95299 2.00696V2.15276V6.60893V6.7366H4.82531H0.131358H0.00433601L0.00418431 6.60893Z", fill: "#00BCD4" }));
|
396
396
|
|
397
397
|
const SvgDatasetList = (props) => /* @__PURE__ */ React__namespace.createElement("svg", { width: "1em", height: "1em", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...props }, /* @__PURE__ */ React__namespace.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M11.4756 6.76071V8.19947C11.4756 8.73156 9.91947 9.16302 8 9.16302C6.08053 9.16302 4.52444 8.73173 4.52444 8.19947V6.76071C4.52444 6.7344 4.5376 6.71182 4.56036 6.69885C4.58311 6.68587 4.60924 6.68605 4.63182 6.69956C5.55129 7.24676 7.39342 7.31307 7.99982 7.31307C8.60622 7.31307 10.4484 7.24676 11.3678 6.69956C11.3904 6.68605 11.4165 6.68587 11.4393 6.69885C11.4624 6.71182 11.4756 6.7344 11.4756 6.76071ZM12.6032 8.94151H15.3159C15.6921 8.94151 16 9.24925 16 9.6256V10.949C16 11.3252 15.6923 11.6331 15.3159 11.6331H12.6032C12.227 11.6331 11.9191 11.3253 11.9191 10.949V9.6256C11.9191 9.24942 12.227 8.94151 12.6032 8.94151ZM3.65689 5.87058C3.77476 5.87058 3.87022 5.96604 3.87022 6.08391C3.87022 6.20178 3.77476 6.29725 3.65689 6.29725H2.25387V7.24356C2.4272 7.32409 2.5472 7.49973 2.5472 7.70329C2.5472 7.98311 2.32036 8.20996 2.04053 8.20996C1.76071 8.20996 1.53387 7.98311 1.53387 7.70329C1.53387 7.49973 1.65404 7.32409 1.8272 7.24356V6.08391C1.8272 5.96604 1.92267 5.87058 2.04053 5.87058H3.65689ZM14.1728 7.24356C14.3461 7.32409 14.4661 7.49973 14.4661 7.70329C14.4661 7.98311 14.2393 8.20996 13.9595 8.20996C13.6796 8.20996 13.4528 7.98311 13.4528 7.70329C13.4528 7.49956 13.573 7.32409 13.7461 7.24356V6.29725H12.3431C12.2252 6.29725 12.1298 6.20178 12.1298 6.08391C12.1298 5.96604 12.2252 5.87058 12.3431 5.87058H13.9595C14.0773 5.87058 14.1728 5.96604 14.1728 6.08391V7.24356ZM8.21333 11.3625C8.38667 11.443 8.50667 11.6185 8.50667 11.8222C8.50667 12.102 8.27982 12.3289 8 12.3289C7.72018 12.3289 7.49333 12.102 7.49333 11.8222C7.49333 11.6187 7.61351 11.443 7.78667 11.3625V9.79858C7.78667 9.68071 7.88213 9.58525 8 9.58525C8.11787 9.58525 8.21333 9.68071 8.21333 9.79858V11.3625ZM0.684089 8.94151H3.3968C3.77298 8.94151 4.08089 9.24925 4.08089 9.6256V10.949C4.08089 11.3252 3.77316 11.6331 3.3968 11.6331H0.684089C0.307911 11.6331 0 11.3252 0 10.949V9.6256C0 9.24942 0.307911 8.94151 0.684089 8.94151ZM1.13013 10.8976H2.95058C3.06844 10.8976 3.16391 10.8021 3.16391 10.6843C3.16391 10.5664 3.06844 10.4709 2.95058 10.4709H1.13013C1.01227 10.4709 0.9168 10.5664 0.9168 10.6843C0.9168 10.8021 1.01244 10.8976 1.13013 10.8976ZM1.13013 10.1038H2.95058C3.06844 10.1038 3.16391 10.0084 3.16391 9.89049C3.16391 9.77262 3.06844 9.67716 2.95058 9.67716H1.13013C1.01227 9.67716 0.9168 9.77262 0.9168 9.89049C0.9168 10.0084 1.01244 10.1038 1.13013 10.1038ZM6.64356 13.0231H9.35644C9.73262 13.0231 10.0405 13.331 10.0405 13.7072V15.0306C10.0405 15.4068 9.7328 15.7147 9.35644 15.7147H6.64356C6.26738 15.7147 5.95947 15.4068 5.95947 15.0306V13.7072C5.95964 13.3308 6.26738 13.0231 6.64356 13.0231ZM7.08978 14.979H8.91022C9.02809 14.979 9.12356 14.8836 9.12356 14.7657C9.12356 14.6478 9.02809 14.5524 8.91022 14.5524H7.08978C6.97191 14.5524 6.87644 14.6478 6.87644 14.7657C6.87644 14.8836 6.97191 14.979 7.08978 14.979ZM7.08978 14.1852H8.91022C9.02809 14.1852 9.12356 14.0898 9.12356 13.9719C9.12356 13.854 9.02809 13.7586 8.91022 13.7586H7.08978C6.97191 13.7586 6.87644 13.854 6.87644 13.9719C6.87644 14.0898 6.97191 14.1852 7.08978 14.1852ZM13.0492 10.8976H14.8697C14.9876 10.8976 15.083 10.8021 15.083 10.6843C15.083 10.5664 14.9876 10.4709 14.8697 10.4709H13.0492C12.9314 10.4709 12.8359 10.5664 12.8359 10.6843C12.8359 10.8021 12.9316 10.8976 13.0492 10.8976ZM13.0492 10.1038H14.8697C14.9876 10.1038 15.083 10.0084 15.083 9.89049C15.083 9.77262 14.9876 9.67716 14.8697 9.67716H13.0492C12.9314 9.67716 12.8359 9.77262 12.8359 9.89049C12.8359 10.0084 12.9316 10.1038 13.0492 10.1038ZM8 0.285156C9.91947 0.285156 11.4756 0.716445 11.4756 1.24871C11.4756 1.7808 9.91947 2.21227 8 2.21227C6.08053 2.21227 4.52444 1.78098 4.52444 1.24871C4.52444 0.716445 6.08053 0.285156 8 0.285156ZM11.4756 2.01209C11.4756 1.98578 11.4624 1.96302 11.4393 1.95022C11.4164 1.93725 11.39 1.93778 11.3675 1.95147C10.6898 2.36267 9.43538 2.63876 8 2.63876C6.56462 2.63876 5.31022 2.36267 4.63253 1.95129C4.60996 1.9376 4.58382 1.93725 4.56071 1.95005C4.53778 1.96302 4.52444 1.9856 4.52444 2.01191V3.45885C4.52444 3.99093 6.08053 4.4224 8 4.4224C9.91947 4.4224 11.4756 3.99111 11.4756 3.45885V2.01209ZM9.45778 3.25067C9.57422 3.23556 9.68089 3.31751 9.69618 3.43396C9.71129 3.5504 9.62933 3.65707 9.51289 3.67236C9.38489 3.68907 9.25458 3.70364 9.12231 3.71591C8.98364 3.72889 8.84996 3.73884 8.72107 3.74631C8.60373 3.75271 8.50329 3.66276 8.49689 3.54542C8.49049 3.42809 8.58044 3.32765 8.69778 3.32125C8.83164 3.3136 8.96071 3.304 9.08391 3.29262C9.20711 3.28124 9.33173 3.2672 9.45778 3.25067ZM10.4039 3.0656C10.5172 3.03431 10.6343 3.1008 10.6656 3.21387C10.6969 3.32711 10.6304 3.44427 10.5173 3.47556L10.4656 3.48996C10.4617 3.49102 10.4578 3.49191 10.4539 3.4928L10.4123 3.50329C10.2987 3.53227 10.1829 3.46364 10.154 3.35004C10.125 3.23644 10.1936 3.12071 10.3072 3.09173C10.3191 3.08871 10.3131 3.09013 10.3467 3.08107L10.3556 3.0784C10.394 3.06827 10.3961 3.06791 10.4039 3.0656ZM11.4756 5.92302V4.29689C11.4756 4.27058 11.4624 4.248 11.4396 4.23502C11.4169 4.22205 11.3908 4.22222 11.3682 4.23573C10.4485 4.78293 8.6064 4.84925 8 4.84925C7.3936 4.84925 5.55147 4.78293 4.632 4.23573C4.60942 4.22222 4.58329 4.22205 4.56053 4.23502C4.53778 4.248 4.52462 4.27058 4.52462 4.29689V5.92302C4.52462 6.45511 6.08071 6.88658 8.00018 6.88658C9.91947 6.88658 11.4756 6.45511 11.4756 5.92302ZM10.4039 5.41333C10.5172 5.38205 10.6343 5.44853 10.6656 5.5616C10.6969 5.67484 10.6304 5.792 10.5173 5.82329L10.466 5.83751C10.4416 5.84409 10.4699 5.83627 10.4123 5.85102C10.2987 5.88 10.1829 5.81138 10.154 5.69778C10.125 5.58418 10.1936 5.46845 10.3072 5.43947C10.3303 5.4336 10.2978 5.4416 10.3559 5.42613L10.4039 5.41333ZM9.45778 5.5984C9.57422 5.58329 9.68089 5.66525 9.69618 5.78169C9.71147 5.89813 9.62933 6.0048 9.51289 6.02009C9.38329 6.03716 9.25138 6.05173 9.11751 6.06418C8.98044 6.07698 8.84818 6.08676 8.72107 6.09405C8.60373 6.10045 8.50329 6.01049 8.49689 5.89316C8.49049 5.77582 8.58044 5.67538 8.69778 5.66898C8.83022 5.66133 8.95769 5.65191 9.07929 5.64071C9.20409 5.62916 9.33031 5.61511 9.45778 5.5984ZM9.45778 7.968C9.33191 7.98453 9.20711 7.9984 9.08373 8.00996C8.96036 8.02151 8.83147 8.03093 8.6976 8.03858C8.58027 8.04498 8.49031 8.14542 8.49671 8.26276C8.50311 8.38009 8.60356 8.47005 8.72089 8.46364C8.84978 8.45618 8.98347 8.44622 9.12213 8.43324C9.2544 8.42098 9.38471 8.4064 9.51271 8.38969C9.62916 8.37458 9.71129 8.26773 9.696 8.15129C9.68071 8.03485 9.57422 7.95289 9.45778 7.968ZM10.4039 7.78311L10.3559 7.79609C10.2978 7.81156 10.3303 7.80338 10.3072 7.80925C10.1936 7.83822 10.1248 7.95396 10.154 8.06756C10.1829 8.18116 10.2987 8.24996 10.4123 8.2208C10.4699 8.20605 10.4416 8.21387 10.466 8.20747L10.5173 8.19307C10.6306 8.16178 10.6969 8.04462 10.6656 7.93138C10.6341 7.81813 10.517 7.75182 10.4039 7.78311Z", fill: "#71347B" }));
|
398
398
|
|
@@ -2907,7 +2907,7 @@ function useMergeRefs(...refs) {
|
|
2907
2907
|
}, [refs]);
|
2908
2908
|
}
|
2909
2909
|
|
2910
|
-
const MAX_SEARCH_CHARACTER_LENGTH =
|
2910
|
+
const MAX_SEARCH_CHARACTER_LENGTH = 100;
|
2911
2911
|
const MAX_ALLOWED_PIXEL = 150;
|
2912
2912
|
const FONT_SIZE$1 = 6;
|
2913
2913
|
const ChipElement = ({
|
@@ -6470,7 +6470,8 @@ const Select$1 = ({
|
|
6470
6470
|
}
|
6471
6471
|
const style = window.getComputedStyle(parent);
|
6472
6472
|
const overflowY = style.overflowY;
|
6473
|
-
const
|
6473
|
+
const overflowX = style.overflowX;
|
6474
|
+
const isScrollable = (overflowY === 'auto' || overflowY === 'scroll' || overflowX === 'auto' || overflowX === 'scroll') && (parent.scrollHeight > parent.clientHeight || parent.scrollWidth > parent.clientWidth);
|
6474
6475
|
if (isScrollable) {
|
6475
6476
|
return parent;
|
6476
6477
|
}
|
@@ -11923,7 +11924,7 @@ const SortableRow = ({
|
|
11923
11924
|
style: {
|
11924
11925
|
position: isFrozen ? 'sticky' : 'static',
|
11925
11926
|
left: isFrozen ? getColumnLeftPosition(index, columns, freezeColumns) : 'auto',
|
11926
|
-
zIndex: isFrozen ?
|
11927
|
+
zIndex: isFrozen ? 120 : 'auto',
|
11927
11928
|
backgroundColor: isFrozen ? 'var(--input-label-bg-color)' : 'transparent',
|
11928
11929
|
width: column.width ? `${column.width}px` : 'auto',
|
11929
11930
|
padding: '7px 8px',
|
@@ -36890,34 +36891,40 @@ function formatePainter(data) {
|
|
36890
36891
|
}
|
36891
36892
|
};
|
36892
36893
|
}
|
36893
|
-
function addRowTop() {
|
36894
|
+
function addRowTop(row) {
|
36894
36895
|
return {
|
36895
|
-
type: ADD_ROW_TOP
|
36896
|
+
type: ADD_ROW_TOP,
|
36897
|
+
row
|
36896
36898
|
};
|
36897
36899
|
}
|
36898
|
-
function addRowBottom() {
|
36900
|
+
function addRowBottom(row) {
|
36899
36901
|
return {
|
36900
|
-
type: ADD_ROW_BOTTOM
|
36902
|
+
type: ADD_ROW_BOTTOM,
|
36903
|
+
row
|
36901
36904
|
};
|
36902
36905
|
}
|
36903
|
-
function addColumnLeft() {
|
36906
|
+
function addColumnLeft(column) {
|
36904
36907
|
return {
|
36905
|
-
type: ADD_COLUMN_LEFT
|
36908
|
+
type: ADD_COLUMN_LEFT,
|
36909
|
+
column
|
36906
36910
|
};
|
36907
36911
|
}
|
36908
|
-
function addColumnRight() {
|
36912
|
+
function addColumnRight(column) {
|
36909
36913
|
return {
|
36910
|
-
type: ADD_COLUMN_RIGHT
|
36914
|
+
type: ADD_COLUMN_RIGHT,
|
36915
|
+
column
|
36911
36916
|
};
|
36912
36917
|
}
|
36913
|
-
function deleteRow() {
|
36918
|
+
function deleteRow(row) {
|
36914
36919
|
return {
|
36915
|
-
type: DELETE_ROW
|
36920
|
+
type: DELETE_ROW,
|
36921
|
+
row
|
36916
36922
|
};
|
36917
36923
|
}
|
36918
|
-
function deleteColumn() {
|
36924
|
+
function deleteColumn(column) {
|
36919
36925
|
return {
|
36920
|
-
type: DELETE_COLUMN
|
36926
|
+
type: DELETE_COLUMN,
|
36927
|
+
column
|
36921
36928
|
};
|
36922
36929
|
}
|
36923
36930
|
function keyPress(event) {
|
@@ -39007,18 +39014,21 @@ function reducer(state, action) {
|
|
39007
39014
|
selectedColumn,
|
39008
39015
|
model
|
39009
39016
|
} = state;
|
39010
|
-
|
39017
|
+
const {
|
39018
|
+
row
|
39019
|
+
} = action;
|
39020
|
+
if (checkEmpty(row ?? selectedRow)) {
|
39011
39021
|
return state;
|
39012
39022
|
}
|
39013
|
-
selectedRow = selectedRow;
|
39023
|
+
selectedRow = row ?? selectedRow;
|
39014
39024
|
let updatedData = [...model.data];
|
39015
39025
|
const newRow = Array(updatedData[0]?.length || 0).fill(EmptyCell);
|
39016
|
-
updatedData.splice(selectedRow, 0, newRow);
|
39026
|
+
updatedData.splice(row ?? selectedRow, 0, newRow);
|
39017
39027
|
const updatedModel = new Model(model.createFormulaParser, updatedData);
|
39018
39028
|
return {
|
39019
39029
|
...state,
|
39020
39030
|
model: updatedModel,
|
39021
|
-
selectedRow: selectedRow,
|
39031
|
+
selectedRow: row ?? selectedRow,
|
39022
39032
|
selectedColumn: selectedColumn
|
39023
39033
|
};
|
39024
39034
|
}
|
@@ -39029,18 +39039,21 @@ function reducer(state, action) {
|
|
39029
39039
|
selectedColumn,
|
39030
39040
|
model
|
39031
39041
|
} = state;
|
39042
|
+
const {
|
39043
|
+
row
|
39044
|
+
} = action;
|
39032
39045
|
if (checkEmpty(selectedRow)) {
|
39033
39046
|
return state;
|
39034
39047
|
}
|
39035
|
-
selectedRow = selectedRow;
|
39048
|
+
selectedRow = row ?? selectedRow;
|
39036
39049
|
let updatedData = [...model.data];
|
39037
39050
|
const newRow = Array(updatedData[0]?.length || 0).fill(EmptyCell);
|
39038
|
-
updatedData.splice(selectedRow + 1, 0, newRow);
|
39051
|
+
updatedData.splice((row ?? selectedRow) + 1, 0, newRow);
|
39039
39052
|
const updatedModel = new Model(model.createFormulaParser, updatedData);
|
39040
39053
|
return {
|
39041
39054
|
...state,
|
39042
39055
|
model: updatedModel,
|
39043
|
-
selectedRow: selectedRow + 1,
|
39056
|
+
selectedRow: (row ?? selectedRow) + 1,
|
39044
39057
|
selectedColumn: selectedColumn
|
39045
39058
|
};
|
39046
39059
|
}
|
@@ -39051,20 +39064,23 @@ function reducer(state, action) {
|
|
39051
39064
|
selectedColumn,
|
39052
39065
|
model
|
39053
39066
|
} = state;
|
39054
|
-
|
39067
|
+
const {
|
39068
|
+
column
|
39069
|
+
} = action;
|
39070
|
+
if (checkEmpty(column ?? selectedColumn)) {
|
39055
39071
|
return state;
|
39056
39072
|
}
|
39057
|
-
selectedColumn = selectedColumn;
|
39073
|
+
selectedColumn = column ?? selectedColumn;
|
39058
39074
|
let updatedData = [...model.data];
|
39059
39075
|
updatedData = updatedData.map(row => {
|
39060
|
-
return [...row.slice(0, selectedColumn), EmptyCell, ...row.slice(selectedColumn)];
|
39076
|
+
return [...row.slice(0, column ?? selectedColumn), EmptyCell, ...row.slice(column ?? selectedColumn)];
|
39061
39077
|
});
|
39062
39078
|
const updatedModel = new Model(model.createFormulaParser, updatedData);
|
39063
39079
|
return {
|
39064
39080
|
...state,
|
39065
39081
|
model: updatedModel,
|
39066
39082
|
selectedRow: selectedRow,
|
39067
|
-
selectedColumn: selectedColumn - 1
|
39083
|
+
selectedColumn: (column ?? selectedColumn) - 1
|
39068
39084
|
};
|
39069
39085
|
}
|
39070
39086
|
case ADD_COLUMN_RIGHT:
|
@@ -39074,20 +39090,23 @@ function reducer(state, action) {
|
|
39074
39090
|
selectedColumn,
|
39075
39091
|
model
|
39076
39092
|
} = state;
|
39077
|
-
|
39093
|
+
const {
|
39094
|
+
column
|
39095
|
+
} = action;
|
39096
|
+
if (checkEmpty(column ?? selectedColumn)) {
|
39078
39097
|
return state;
|
39079
39098
|
}
|
39080
|
-
selectedColumn = selectedColumn;
|
39099
|
+
selectedColumn = column ?? selectedColumn;
|
39081
39100
|
let updatedData = [...model.data];
|
39082
39101
|
updatedData = updatedData.map(row => {
|
39083
|
-
return [...row.slice(0, selectedColumn + 1), EmptyCell, ...row.slice(selectedColumn + 1)];
|
39102
|
+
return [...row.slice(0, (column ?? selectedColumn) + 1), EmptyCell, ...row.slice((column ?? selectedColumn) + 1)];
|
39084
39103
|
});
|
39085
39104
|
const updatedModel = new Model(model.createFormulaParser, updatedData);
|
39086
39105
|
return {
|
39087
39106
|
...state,
|
39088
39107
|
model: updatedModel,
|
39089
39108
|
selectedRow: selectedRow,
|
39090
|
-
selectedColumn: selectedColumn + 1
|
39109
|
+
selectedColumn: (column ?? selectedColumn) + 1
|
39091
39110
|
};
|
39092
39111
|
}
|
39093
39112
|
case DELETE_ROW:
|
@@ -39097,14 +39116,17 @@ function reducer(state, action) {
|
|
39097
39116
|
selectedColumn,
|
39098
39117
|
model
|
39099
39118
|
} = state;
|
39119
|
+
const {
|
39120
|
+
row
|
39121
|
+
} = action;
|
39100
39122
|
if (checkEmpty(selectedRow)) {
|
39101
39123
|
return state;
|
39102
39124
|
}
|
39103
|
-
selectedRow = selectedRow;
|
39125
|
+
selectedRow = row ?? selectedRow;
|
39104
39126
|
let updatedData = [...model.data];
|
39105
|
-
updatedData.splice(selectedRow, 1);
|
39127
|
+
updatedData.splice(row ?? selectedRow, 1);
|
39106
39128
|
const updatedModel = new Model(model.createFormulaParser, updatedData);
|
39107
|
-
let newSelectedRow = selectedRow > 0 ? selectedRow - 1 : 0;
|
39129
|
+
let newSelectedRow = row ?? selectedRow > 0 ? row ?? selectedRow - 1 : 0;
|
39108
39130
|
const newSelectedColumn = selectedColumn !== null ? selectedColumn : 0;
|
39109
39131
|
const newActive = updatedData.length > 0 ? {
|
39110
39132
|
row: newSelectedRow,
|
@@ -39112,7 +39134,7 @@ function reducer(state, action) {
|
|
39112
39134
|
} : null;
|
39113
39135
|
const newSelected = updatedData.length > 0 ? new EntireRowsSelection(newSelectedRow, newSelectedRow) : new EmptySelection();
|
39114
39136
|
const {
|
39115
|
-
[selectedRow]: _,
|
39137
|
+
[row ?? selectedRow]: _,
|
39116
39138
|
...cleanedRowDimensions
|
39117
39139
|
} = state.rowDimensions;
|
39118
39140
|
return {
|
@@ -39132,8 +39154,11 @@ function reducer(state, action) {
|
|
39132
39154
|
selectedColumn,
|
39133
39155
|
model
|
39134
39156
|
} = state;
|
39135
|
-
|
39136
|
-
|
39157
|
+
const {
|
39158
|
+
column
|
39159
|
+
} = action;
|
39160
|
+
if (checkEmpty(column ?? selectedColumn)) return state;
|
39161
|
+
const colIndex = column ?? selectedColumn;
|
39137
39162
|
const updatedData = model.data.map(row => row.filter((_, cellIndex) => cellIndex !== colIndex));
|
39138
39163
|
const updatedModel = new Model(model.createFormulaParser, updatedData);
|
39139
39164
|
const newSelectedRow = selectedRow || 0;
|
@@ -41103,7 +41128,9 @@ const ColumnIndicator = ({
|
|
41103
41128
|
cell,
|
41104
41129
|
selectedColumn,
|
41105
41130
|
minimumColumnWidth,
|
41106
|
-
maxColLimit
|
41131
|
+
maxColLimit,
|
41132
|
+
disableDeleteOption,
|
41133
|
+
contextMenu
|
41107
41134
|
}) => {
|
41108
41135
|
const dispatch = useDispatch();
|
41109
41136
|
const minColumnWidth = minimumColumnWidth;
|
@@ -41117,7 +41144,7 @@ const ColumnIndicator = ({
|
|
41117
41144
|
label: 'Add Column Left',
|
41118
41145
|
value: 'Add Column Left',
|
41119
41146
|
iconName: 'plus_icon',
|
41120
|
-
action: addColumnLeft,
|
41147
|
+
action: () => addColumnLeft(),
|
41121
41148
|
disableTooltip: 'Column limit reached',
|
41122
41149
|
visible: cell?.contextDisable?.['Add Column Left'] ?? false,
|
41123
41150
|
disable: columnCount >= maxColLimit
|
@@ -41125,19 +41152,19 @@ const ColumnIndicator = ({
|
|
41125
41152
|
label: 'Add Column Right',
|
41126
41153
|
value: 'Add Column Right',
|
41127
41154
|
iconName: 'plus_icon',
|
41128
|
-
action: addColumnRight,
|
41155
|
+
action: () => addColumnRight(),
|
41129
41156
|
disableTooltip: 'Column limit reached',
|
41130
41157
|
visible: cell?.contextDisable?.['Add Column Right'] ?? false,
|
41131
41158
|
disable: columnCount >= maxColLimit
|
41132
|
-
}, {
|
41159
|
+
}, ...(!disableDeleteOption ? [{
|
41133
41160
|
label: 'Delete Column',
|
41134
41161
|
value: 'Delete Column',
|
41135
41162
|
iconName: 'delete',
|
41136
|
-
action: deleteColumn,
|
41137
|
-
disableTooltip: '
|
41163
|
+
action: () => deleteColumn(),
|
41164
|
+
disableTooltip: '',
|
41138
41165
|
visible: cell?.contextDisable?.['Delete Column'] ?? false,
|
41139
41166
|
disable: false
|
41140
|
-
}];
|
41167
|
+
}] : [])];
|
41141
41168
|
}, [selectedColumn, cell, addColumnLeft, addColumnRight, deleteColumn]);
|
41142
41169
|
const onMouseDrag = React__namespace.useCallback((event, isRight) => {
|
41143
41170
|
const getTargetColumn = isRight ? column - 1 : column;
|
@@ -41167,17 +41194,19 @@ const ColumnIndicator = ({
|
|
41167
41194
|
onSelect(column, event.shiftKey);
|
41168
41195
|
setContextMenu({
|
41169
41196
|
open: columnContextEnable,
|
41197
|
+
contextType: 'column',
|
41170
41198
|
options
|
41171
41199
|
});
|
41172
41200
|
}, [column, selectedColumn, columnContextEnable, options]);
|
41173
41201
|
React__namespace.useEffect(() => {
|
41174
|
-
if (selectedColumn !== undefined) {
|
41202
|
+
if (selectedColumn !== undefined && contextMenu?.contextType === 'column' || !contextMenu?.contextType) {
|
41175
41203
|
setContextMenu(prev => ({
|
41176
41204
|
open: prev.open,
|
41205
|
+
contextType: 'column',
|
41177
41206
|
options
|
41178
41207
|
}));
|
41179
41208
|
}
|
41180
|
-
}, [column, selectedColumn, columnContextEnable, options]);
|
41209
|
+
}, [column, selectedColumn, columnContextEnable, options, contextMenu?.contextType]);
|
41181
41210
|
return jsxRuntime.jsxs("th", {
|
41182
41211
|
className: classNames('ff-spreadsheet-header', {
|
41183
41212
|
'ff-spreadsheet-header--selected': selected
|
@@ -41249,7 +41278,9 @@ const RowIndicator = ({
|
|
41249
41278
|
rowContextEnable,
|
41250
41279
|
selectedRow,
|
41251
41280
|
cell,
|
41252
|
-
maxRowLimit
|
41281
|
+
maxRowLimit,
|
41282
|
+
disableDeleteOption,
|
41283
|
+
contextMenu
|
41253
41284
|
}) => {
|
41254
41285
|
const dispatch = useDispatch();
|
41255
41286
|
const rowHeight = useSelector(state => state.rowDimensions[row]?.height || 32);
|
@@ -41262,7 +41293,7 @@ const RowIndicator = ({
|
|
41262
41293
|
label: 'Add Row Top',
|
41263
41294
|
value: 'Add Row Top',
|
41264
41295
|
iconName: 'plus_icon',
|
41265
|
-
action: addRowTop,
|
41296
|
+
action: () => addRowTop(),
|
41266
41297
|
disableTooltip: 'Row limit reached',
|
41267
41298
|
visible: cell?.contextDisable?.['Add Row Top'] ?? false,
|
41268
41299
|
disable: rowCount >= maxRowLimit
|
@@ -41270,20 +41301,20 @@ const RowIndicator = ({
|
|
41270
41301
|
label: 'Add Row Bottom',
|
41271
41302
|
value: 'Add Row Bottom',
|
41272
41303
|
iconName: 'plus_icon',
|
41273
|
-
action: addRowBottom,
|
41304
|
+
action: () => addRowBottom(),
|
41274
41305
|
disableTooltip: 'Row limit reached',
|
41275
41306
|
visible: cell?.contextDisable?.['Add Row Bottom'] ?? false,
|
41276
41307
|
disable: rowCount >= maxRowLimit
|
41277
|
-
}, {
|
41308
|
+
}, ...(!disableDeleteOption ? [{
|
41278
41309
|
label: 'Delete Row',
|
41279
41310
|
value: 'Delete Row',
|
41280
41311
|
iconName: 'delete',
|
41281
|
-
action: deleteRow,
|
41282
|
-
disableTooltip: '
|
41312
|
+
action: () => deleteRow(),
|
41313
|
+
disableTooltip: '',
|
41283
41314
|
visible: cell?.contextDisable?.['Delete Row'] ?? false,
|
41284
41315
|
disable: false
|
41285
|
-
}];
|
41286
|
-
}, [selectedRow]);
|
41316
|
+
}] : [])];
|
41317
|
+
}, [selectedRow, row]);
|
41287
41318
|
const handleMouseDrag = React__namespace.useCallback((event, isUp) => {
|
41288
41319
|
const getTargetRow = isUp ? row : row - 1;
|
41289
41320
|
const targetRow = Math.max(getTargetRow, 0);
|
@@ -41312,17 +41343,19 @@ const RowIndicator = ({
|
|
41312
41343
|
onSelect(row, event.shiftKey);
|
41313
41344
|
setContextMenu({
|
41314
41345
|
open: rowContextEnable,
|
41346
|
+
contextType: 'row',
|
41315
41347
|
options
|
41316
41348
|
});
|
41317
41349
|
}, [row, rowContextEnable, options, selectedRow]);
|
41318
41350
|
React__namespace.useEffect(() => {
|
41319
|
-
if (selectedRow !== undefined) {
|
41351
|
+
if (selectedRow !== undefined && contextMenu?.contextType === 'row' || !contextMenu?.contextType) {
|
41320
41352
|
setContextMenu(prev => ({
|
41321
41353
|
open: prev.open,
|
41354
|
+
contextType: 'row',
|
41322
41355
|
options
|
41323
41356
|
}));
|
41324
41357
|
}
|
41325
|
-
}, [row, rowContextEnable, options, selectedRow]);
|
41358
|
+
}, [row, rowContextEnable, options, selectedRow, contextMenu?.contextType]);
|
41326
41359
|
return jsxRuntime.jsxs("th", {
|
41327
41360
|
className: classNames('ff-spreadsheet-header', {
|
41328
41361
|
'ff-spreadsheet-header--selected': selected
|
@@ -41953,6 +41986,7 @@ const ActiveCell = props => {
|
|
41953
41986
|
event.preventDefault();
|
41954
41987
|
props.setContextMenu({
|
41955
41988
|
open: props.contextOption?.open ?? false,
|
41989
|
+
contextType: props.contextOption?.contextType ?? null,
|
41956
41990
|
options: props.contextOption?.options || []
|
41957
41991
|
});
|
41958
41992
|
}, [props]);
|
@@ -42623,7 +42657,9 @@ const Spreadsheet = props => {
|
|
42623
42657
|
setContextMenu,
|
42624
42658
|
showHider,
|
42625
42659
|
maxRowLimit,
|
42626
|
-
maxColLimit
|
42660
|
+
maxColLimit,
|
42661
|
+
disableDeleteOption,
|
42662
|
+
contextMenu
|
42627
42663
|
} = props;
|
42628
42664
|
const [sheetChange, setSheetChange] = React__namespace.useState(false);
|
42629
42665
|
const [maxWidth, setMaxWidth] = React__namespace.useState(0);
|
@@ -42920,6 +42956,7 @@ const Spreadsheet = props => {
|
|
42920
42956
|
});
|
42921
42957
|
setContextMenu({
|
42922
42958
|
open: false,
|
42959
|
+
contextType: null,
|
42923
42960
|
options: [{
|
42924
42961
|
label: '',
|
42925
42962
|
value: '',
|
@@ -42952,7 +42989,9 @@ const Spreadsheet = props => {
|
|
42952
42989
|
addColumnLeft: addColumnLeft$1,
|
42953
42990
|
addColumnRight: addColumnRight$1,
|
42954
42991
|
columnContextEnable: props.columnContextEnable,
|
42955
|
-
maxColLimit: maxColLimit
|
42992
|
+
maxColLimit: maxColLimit,
|
42993
|
+
disableDeleteOption: disableDeleteOption,
|
42994
|
+
contextMenu: contextMenu
|
42956
42995
|
}, columnNumber) : jsxRuntime.jsx(ColumnIndicator, {
|
42957
42996
|
column: columnNumber,
|
42958
42997
|
minimumColumnWidth: minimumColumnWidth,
|
@@ -42961,7 +43000,9 @@ const Spreadsheet = props => {
|
|
42961
43000
|
addColumnLeft: addColumnLeft$1,
|
42962
43001
|
addColumnRight: addColumnRight$1,
|
42963
43002
|
columnContextEnable: props.columnContextEnable,
|
42964
|
-
maxColLimit: maxColLimit
|
43003
|
+
maxColLimit: maxColLimit,
|
43004
|
+
disableDeleteOption: disableDeleteOption,
|
43005
|
+
contextMenu: contextMenu
|
42965
43006
|
}, columnNumber))]
|
42966
43007
|
}), renderReady && scrollerFunction().map(rowNumber => jsxRuntime.jsxs(Row$1, {
|
42967
43008
|
row: rowNumber,
|
@@ -42973,7 +43014,9 @@ const Spreadsheet = props => {
|
|
42973
43014
|
deleteRow: deleteRow$1,
|
42974
43015
|
setContextMenu: props.setContextMenu,
|
42975
43016
|
rowContextEnable: props.rowContextEnable,
|
42976
|
-
maxRowLimit: maxRowLimit
|
43017
|
+
maxRowLimit: maxRowLimit,
|
43018
|
+
disableDeleteOption: disableDeleteOption,
|
43019
|
+
contextMenu: contextMenu
|
42977
43020
|
}, rowNumber) : jsxRuntime.jsx(RowIndicator$1, {
|
42978
43021
|
row: rowNumber,
|
42979
43022
|
addRowTop: addRowTop$1,
|
@@ -42981,7 +43024,9 @@ const Spreadsheet = props => {
|
|
42981
43024
|
deleteRow: deleteRow$1,
|
42982
43025
|
setContextMenu: props.setContextMenu,
|
42983
43026
|
rowContextEnable: props.rowContextEnable,
|
42984
|
-
maxRowLimit: maxRowLimit
|
43027
|
+
maxRowLimit: maxRowLimit,
|
43028
|
+
disableDeleteOption: disableDeleteOption,
|
43029
|
+
contextMenu: contextMenu
|
42985
43030
|
}, rowNumber), range(size.columns).map(columnNumber => jsxRuntime.jsx(Cell$1, {
|
42986
43031
|
row: rowNumber,
|
42987
43032
|
column: columnNumber,
|
@@ -43045,6 +43090,7 @@ const Spreadsheet = props => {
|
|
43045
43090
|
scrollOption && throttledHandleScroll(e);
|
43046
43091
|
setContextMenu({
|
43047
43092
|
open: false,
|
43093
|
+
contextType: null,
|
43048
43094
|
options: [{
|
43049
43095
|
label: '',
|
43050
43096
|
value: '',
|
@@ -43068,15 +43114,12 @@ const Spreadsheet = props => {
|
|
43068
43114
|
const ExcelContextMenu = ({
|
43069
43115
|
contextMenu,
|
43070
43116
|
position,
|
43071
|
-
editable
|
43072
|
-
disableDeleteOption
|
43117
|
+
editable
|
43073
43118
|
}) => {
|
43119
|
+
if (!contextMenu.open) return null;
|
43074
43120
|
const checkDelete = label => {
|
43075
43121
|
return label.includes('Delete');
|
43076
43122
|
};
|
43077
|
-
const isOptionDisabled = option => {
|
43078
|
-
return option.disable || checkDelete(option.label) && disableDeleteOption;
|
43079
|
-
};
|
43080
43123
|
return editable && jsxRuntime.jsx("div", {
|
43081
43124
|
onContextMenu: event => {
|
43082
43125
|
event.preventDefault();
|
@@ -43091,7 +43134,7 @@ const ExcelContextMenu = ({
|
|
43091
43134
|
},
|
43092
43135
|
children: contextMenu.options.map(option => {
|
43093
43136
|
if (!option.visible) {
|
43094
|
-
const disabled =
|
43137
|
+
const disabled = option.disable;
|
43095
43138
|
return jsxRuntime.jsx(Tooltip, {
|
43096
43139
|
title: disabled ? option.disableTooltip : '',
|
43097
43140
|
children: jsxRuntime.jsxs("div", {
|
@@ -43171,6 +43214,7 @@ const ExcelFile = ({
|
|
43171
43214
|
const [saveInfo, setSaveInfo] = React.useState('');
|
43172
43215
|
const [contextMenu, setContextMenu] = React.useState({
|
43173
43216
|
open: false,
|
43217
|
+
contextType: null,
|
43174
43218
|
options: [{
|
43175
43219
|
label: '',
|
43176
43220
|
value: '',
|
@@ -43483,28 +43527,34 @@ const ExcelFile = ({
|
|
43483
43527
|
selection?.removeAllRanges();
|
43484
43528
|
selection?.addRange(range);
|
43485
43529
|
};
|
43486
|
-
const handleClickOutside = React.useCallback(event => {
|
43487
|
-
|
43488
|
-
|
43489
|
-
|
43490
|
-
|
43491
|
-
|
43492
|
-
|
43493
|
-
|
43494
|
-
|
43495
|
-
|
43496
|
-
|
43497
|
-
|
43498
|
-
|
43499
|
-
|
43500
|
-
|
43501
|
-
|
43530
|
+
const handleClickOutside = React.useCallback((event, isLeftClick = false) => {
|
43531
|
+
const target = event.target;
|
43532
|
+
if (!(target.closest('.ff-excel-tab-list') || target.closest('.ff-excel-sheet')) || isLeftClick) {
|
43533
|
+
if (contextMenu.open) {
|
43534
|
+
event.preventDefault();
|
43535
|
+
event.stopPropagation();
|
43536
|
+
setContextMenu({
|
43537
|
+
open: false,
|
43538
|
+
contextType: null,
|
43539
|
+
options: [{
|
43540
|
+
label: '',
|
43541
|
+
value: '',
|
43542
|
+
iconName: '',
|
43543
|
+
action: () => {},
|
43544
|
+
disableTooltip: '',
|
43545
|
+
visible: false,
|
43546
|
+
disable: false
|
43547
|
+
}]
|
43548
|
+
});
|
43549
|
+
}
|
43502
43550
|
}
|
43503
43551
|
}, [contextMenu.open]);
|
43504
43552
|
React.useEffect(() => {
|
43505
|
-
document.addEventListener('
|
43553
|
+
document.addEventListener('contextmenu', handleClickOutside);
|
43554
|
+
document.addEventListener('click', e => handleClickOutside(e, true));
|
43506
43555
|
return () => {
|
43507
|
-
document.removeEventListener('
|
43556
|
+
document.removeEventListener('contextmenu', handleClickOutside);
|
43557
|
+
document.addEventListener('click', e => handleClickOutside(e, true));
|
43508
43558
|
};
|
43509
43559
|
}, [handleClickOutside]);
|
43510
43560
|
const contextClick = (event, name, index) => {
|
@@ -43513,27 +43563,24 @@ const ExcelFile = ({
|
|
43513
43563
|
label: 'Add Sheet',
|
43514
43564
|
value: 'Add Sheet',
|
43515
43565
|
iconName: 'plus_icon',
|
43516
|
-
action: () =>
|
43517
|
-
handleAddSheet();
|
43518
|
-
},
|
43566
|
+
action: () => handleAddSheet(),
|
43519
43567
|
disableTooltip: 'Sheet limit reached',
|
43520
43568
|
visible: false,
|
43521
43569
|
disable: addSheetIconDisable()
|
43522
|
-
}, {
|
43570
|
+
}, ...(!disableDeleteOption ? [{
|
43523
43571
|
label: 'Delete Sheet',
|
43524
43572
|
value: 'Delete Sheet',
|
43525
43573
|
iconName: 'delete',
|
43526
|
-
action: () =>
|
43527
|
-
handleDeleteSheet(name, index);
|
43528
|
-
},
|
43574
|
+
action: () => handleDeleteSheet(name, index),
|
43529
43575
|
disableTooltip: '',
|
43530
43576
|
visible: false,
|
43531
43577
|
disable: false
|
43532
|
-
}];
|
43578
|
+
}] : [])];
|
43533
43579
|
setContextMenu(prev => ({
|
43534
43580
|
...prev,
|
43535
43581
|
open: true,
|
43536
|
-
|
43582
|
+
contextType: 'sheet',
|
43583
|
+
options
|
43537
43584
|
}));
|
43538
43585
|
};
|
43539
43586
|
const setContextPosition = event => {
|
@@ -43566,7 +43613,7 @@ const ExcelFile = ({
|
|
43566
43613
|
if (event.target.classList.contains('ff-excel-tab-list')) {
|
43567
43614
|
setPosition({
|
43568
43615
|
x: sheetRefX,
|
43569
|
-
y: sheetRefY - 65
|
43616
|
+
y: sheetRefY - (disableDeleteOption ? 32 : 65)
|
43570
43617
|
});
|
43571
43618
|
return;
|
43572
43619
|
}
|
@@ -43587,6 +43634,7 @@ const ExcelFile = ({
|
|
43587
43634
|
if (contextMenu.open) {
|
43588
43635
|
setContextMenu({
|
43589
43636
|
open: false,
|
43637
|
+
contextType: null,
|
43590
43638
|
options: [{
|
43591
43639
|
label: '',
|
43592
43640
|
value: '',
|
@@ -43624,7 +43672,9 @@ const ExcelFile = ({
|
|
43624
43672
|
scroller: scroller,
|
43625
43673
|
showHider: showHider,
|
43626
43674
|
maxRowLimit: maxRowLimit,
|
43627
|
-
maxColLimit: maxColLimit
|
43675
|
+
maxColLimit: maxColLimit,
|
43676
|
+
disableDeleteOption: disableDeleteOption,
|
43677
|
+
contextMenu: contextMenu
|
43628
43678
|
})
|
43629
43679
|
}), sheetBar !== 'hide' && jsxRuntime.jsxs("div", {
|
43630
43680
|
className: "ff-excel-sheet-bar",
|
@@ -43686,8 +43736,7 @@ const ExcelFile = ({
|
|
43686
43736
|
}), contextMenu.open && jsxRuntime.jsx(ExcelContextMenu, {
|
43687
43737
|
contextMenu: contextMenu,
|
43688
43738
|
position: position,
|
43689
|
-
editable: editable
|
43690
|
-
disableDeleteOption: disableDeleteOption
|
43739
|
+
editable: editable
|
43691
43740
|
}), jsxRuntime.jsx(Toastify, {})]
|
43692
43741
|
})
|
43693
43742
|
});
|
@@ -65332,7 +65381,7 @@ const Comments = ({
|
|
65332
65381
|
if (mentionNameMatch) {
|
65333
65382
|
const mentionNameStart = textBeforeCaret.lastIndexOf(mentionNameMatch[1] ?? '');
|
65334
65383
|
const remainingText = input.slice(caretPosition);
|
65335
|
-
const mentionedUserName = `@${name
|
65384
|
+
const mentionedUserName = `@${name} `;
|
65336
65385
|
const newText = input.slice(0, mentionNameStart) + mentionedUserName + remainingText;
|
65337
65386
|
setInput(newText);
|
65338
65387
|
setHasAtSymbol(false);
|