mirror of https://github.com/fantasticit/think.git
parent
f9bcf31df0
commit
1d2c9402f2
|
@ -4,6 +4,7 @@ import 'styles/globals.scss';
|
||||||
import 'tiptap/core/styles/index.scss';
|
import 'tiptap/core/styles/index.scss';
|
||||||
import '@react-pdf-viewer/core/lib/styles/index.css';
|
import '@react-pdf-viewer/core/lib/styles/index.css';
|
||||||
import '@react-pdf-viewer/default-layout/lib/styles/index.css';
|
import '@react-pdf-viewer/default-layout/lib/styles/index.css';
|
||||||
|
import 'thirtypart/array-prototype-at';
|
||||||
|
|
||||||
import { Worker } from '@react-pdf-viewer/core';
|
import { Worker } from '@react-pdf-viewer/core';
|
||||||
import { isMobile } from 'helpers/env';
|
import { isMobile } from 'helpers/env';
|
||||||
|
|
|
@ -0,0 +1,8 @@
|
||||||
|
if (![].at) {
|
||||||
|
Array.prototype.at = function at(n) {
|
||||||
|
n = Math.trunc(n) || 0;
|
||||||
|
if (n < 0) n += this.length;
|
||||||
|
if (n < 0 || n >= this.length) return undefined;
|
||||||
|
return this[n];
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in New Issue