@elice/material-pdf 1.240306.0-runboxtutoring.0 → 1.240306.0

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 (27) hide show
  1. package/cjs/components/material-pdf/MaterialPdf.d.ts +2 -3
  2. package/cjs/components/material-pdf/MaterialPdf.js +21 -26
  3. package/cjs/components/material-pdf/MaterialPdf.styled.js +2 -6
  4. package/cjs/components/material-pdf/MaterialPdfContent.js +37 -66
  5. package/cjs/components/material-pdf/locales.d.ts +7 -0
  6. package/cjs/components/material-pdf/locales.js +17 -0
  7. package/es/components/material-pdf/MaterialPdf.d.ts +2 -3
  8. package/es/components/material-pdf/MaterialPdf.js +22 -22
  9. package/es/components/material-pdf/MaterialPdf.styled.js +2 -2
  10. package/es/components/material-pdf/MaterialPdfContent.js +39 -64
  11. package/es/components/material-pdf/locales.d.ts +7 -0
  12. package/es/components/material-pdf/locales.js +14 -0
  13. package/package.json +15 -12
  14. package/cjs/components/material-pdf/index.js +0 -7
  15. package/cjs/components/material-pdf/locales/en.json.js +0 -7
  16. package/cjs/components/material-pdf/locales/index.d.ts +0 -4
  17. package/cjs/components/material-pdf/locales/index.js +0 -13
  18. package/cjs/components/material-pdf/locales/ja.json.js +0 -7
  19. package/cjs/components/material-pdf/locales/ko.json.js +0 -7
  20. package/cjs/components/material-pdf/locales/th.json.js +0 -7
  21. package/es/components/material-pdf/index.js +0 -1
  22. package/es/components/material-pdf/locales/en.json.js +0 -3
  23. package/es/components/material-pdf/locales/index.d.ts +0 -4
  24. package/es/components/material-pdf/locales/index.js +0 -4
  25. package/es/components/material-pdf/locales/ja.json.js +0 -3
  26. package/es/components/material-pdf/locales/ko.json.js +0 -3
  27. package/es/components/material-pdf/locales/th.json.js +0 -3
@@ -1,10 +1,9 @@
1
1
  import React from 'react';
2
- import type { WithIntlComponentBuilderProps } from '@elice/intl';
3
2
  export interface MaterialPdfProps {
4
3
  className?: string;
5
4
  materialPdfId: number;
6
5
  cMapUrl?: string;
7
6
  locale?: string;
8
7
  }
9
- declare const _default: React.ForwardRefExoticComponent<import("@elice/intl").IntlComponentExtraProps & Omit<WithIntlComponentBuilderProps<MaterialPdfProps>, keyof import("@elice/intl").IntlComponentExtraProps | "__intl"> & React.RefAttributes<any>>;
10
- export default _default;
8
+ declare const MaterialPdf: React.FC<MaterialPdfProps>;
9
+ export default MaterialPdf;
@@ -2,38 +2,33 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var jsxRuntime = require('react/jsx-runtime');
6
- var intl = require('@elice/intl');
5
+ var React = require('react');
6
+ var reactIntl = require('react-intl');
7
7
  var classnames = require('classnames');
8
- var en = require('./locales/en.json.js');
9
- var ko = require('./locales/ko.json.js');
8
+ var locales = require('./locales.js');
10
9
  var MaterialPdfContent = require('./MaterialPdfContent.js');
11
10
  var MaterialPdf_styled = require('./MaterialPdf.styled.js');
12
11
 
13
- function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'default' in e ? e : { default: e }; }
14
-
15
- var classnames__default = /*#__PURE__*/_interopDefaultCompat(classnames);
16
-
17
- var MaterialPdf = function MaterialPdf(_ref) {
18
- var className = _ref.className,
19
- materialPdfId = _ref.materialPdfId,
20
- cMapUrl = _ref.cMapUrl,
21
- __intl = _ref.__intl;
22
- var prefixCls = 'em-material-pdf';
12
+ const MaterialPdf = ({
13
+ className,
14
+ materialPdfId,
15
+ cMapUrl,
16
+ locale = 'en'
17
+ }) => {
18
+ const prefixCls = 'em-material-pdf';
23
19
  //
24
20
  //
25
21
  //
26
- return jsxRuntime.jsx(intl.RawEliceIntlProvider, {
27
- value: __intl,
28
- children: jsxRuntime.jsx(MaterialPdf_styled.StyledMaterialPdfWrapper, {
29
- className: classnames__default.default(prefixCls, className),
30
- children: jsxRuntime.jsx(MaterialPdfContent.default, {
31
- materialPdfId: materialPdfId,
32
- cMapUrl: cMapUrl
33
- })
34
- })
35
- });
22
+ return React.createElement(MaterialPdf_styled.StyledMaterialPdfWrapper, {
23
+ className: classnames(prefixCls, className)
24
+ }, React.createElement(reactIntl.IntlProvider, {
25
+ locale: locale,
26
+ defaultLocale: "en",
27
+ messages: locale in locales ? locales[locale] : locales.en
28
+ }, React.createElement(MaterialPdfContent.default, {
29
+ materialPdfId: materialPdfId,
30
+ cMapUrl: cMapUrl
31
+ })));
36
32
  };
37
- var MaterialPdf$1 = new intl.IntlComponentBuilder(MaterialPdf).add('en', en.default).add('ko', ko.default).addAsync('th', Promise.resolve().then(function () { return require('./locales/th.json.js'); })).addAsync('ja', Promise.resolve().then(function () { return require('./locales/ja.json.js'); })).build();
38
33
 
39
- exports.default = MaterialPdf$1;
34
+ exports.default = MaterialPdf;
@@ -2,12 +2,8 @@
2
2
 
3
3
  var styled = require('styled-components');
4
4
 
5
- function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'default' in e ? e : { default: e }; }
6
-
7
- var styled__default = /*#__PURE__*/_interopDefaultCompat(styled);
8
-
9
- var StyledMaterialPdfWrapper = styled__default.default.div.withConfig({
5
+ const StyledMaterialPdfWrapper = styled.div.withConfig({
10
6
  componentId: "sc-hovq54-0"
11
- })(["margin:0;flex:2 1;width:100%;height:100%;overflow:hidden;background-color:#22222c;"]);
7
+ })(["margin:0;flex:2 1;height:100%;background-color:#22222c;"]);
12
8
 
13
9
  exports.StyledMaterialPdfWrapper = StyledMaterialPdfWrapper;
@@ -2,83 +2,54 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var jsxRuntime = require('react/jsx-runtime');
6
5
  var React = require('react');
6
+ var reactIntl = require('react-intl');
7
7
  var apiClient = require('@elice/api-client');
8
8
  var blocks = require('@elice/blocks');
9
- var intl = require('@elice/intl');
10
9
  var materialSharedUtils = require('@elice/material-shared-utils');
11
10
  var types = require('@elice/types');
12
11
 
13
- function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'default' in e ? e : { default: e }; }
14
-
15
- var React__default = /*#__PURE__*/_interopDefaultCompat(React);
16
-
17
12
  //
18
13
  //
19
14
  //
20
- var POWERPOINT_EXTENSIONS = ['ppt', 'pptx', 'pps', 'ppsx'];
21
- var MaterialPdfContent = function MaterialPdfContent(_ref) {
22
- var materialPdfId = _ref.materialPdfId,
23
- cMapUrl = _ref.cMapUrl;
24
- var intl$1 = intl.useRawEliceIntl();
25
- var _useMaterialFetch = materialSharedUtils.useMaterialFetch(types.enums.LectureMaterialType.PDF, React__default.default.useCallback(function (signal) {
26
- return apiClient.getOrgMaterialPdfGet({
27
- materialPdfId: materialPdfId
28
- }, {
29
- signal: signal
30
- });
31
- }, [materialPdfId]), apiClient.config.init),
32
- materialPdf = _useMaterialFetch.materialPdf,
33
- materialPdfStatus = _useMaterialFetch.status;
34
- var isPowerPointFile = React.useMemo(function () {
35
- var _a, _b;
36
- if (!(materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url)) return false;
37
- var _URL = new URL(materialPdf.attachment.url),
38
- pathname = _URL.pathname;
39
- var currentFileName = (_a = pathname.split('/').pop()) !== null && _a !== void 0 ? _a : '';
40
- var currentFileExtension = (_b = currentFileName.split('.').pop()) !== null && _b !== void 0 ? _b : '';
41
- return POWERPOINT_EXTENSIONS.some(function (extension) {
42
- return currentFileExtension.toLowerCase().includes(extension);
43
- });
44
- }, [materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url]);
45
- var componentProps = React.useMemo(function () {
46
- var _a;
47
- return isPowerPointFile ? {
48
- type: 'powerpoint',
49
- src: materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url,
50
- i18n: {
51
- error: intl$1.formatMessage({
52
- id: 'pdf.status.error'
53
- })
54
- }
55
- } : {
56
- type: 'pdf',
57
- key: materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url,
58
- file: (_a = materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url) !== null && _a !== void 0 ? _a : '',
59
- title: materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.title,
60
- cMapUrl: cMapUrl,
61
- hasError: !(materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url) || materialPdfStatus === 'rejected',
62
- i18n: {
63
- fullscreen: intl$1.formatMessage({
64
- id: 'pdf.fullScreen'
65
- }),
66
- download: intl$1.formatMessage({
67
- id: 'pdf.download'
68
- }),
69
- loading: intl$1.formatMessage({
70
- id: 'pdf.status.loading'
71
- }),
72
- error: intl$1.formatMessage({
73
- id: 'pdf.status.error'
74
- })
75
- }
76
- };
77
- }, [cMapUrl, intl$1, isPowerPointFile, materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url, materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.title, materialPdfStatus]);
15
+ const MaterialPdfContent = ({
16
+ materialPdfId,
17
+ cMapUrl
18
+ }) => {
19
+ var _a;
20
+ const intl = reactIntl.useIntl();
21
+ const {
22
+ materialPdf,
23
+ status: materialPdfStatus
24
+ } = materialSharedUtils.useMaterialFetch(types.enums.LectureMaterialType.PDF, React.useCallback(signal => apiClient.getOrgMaterialPdfGet({
25
+ materialPdfId
26
+ }, {
27
+ signal
28
+ }), [materialPdfId]), apiClient.config.init);
78
29
  if (materialPdfStatus === 'pending') {
79
- return jsxRuntime.jsx(blocks.Spinner, {});
30
+ return React.createElement(blocks.Spinner, null);
80
31
  }
81
- return jsxRuntime.jsx(blocks.DocumentRenderer, Object.assign({}, componentProps));
32
+ return React.createElement(blocks.PdfRenderer, {
33
+ key: materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url,
34
+ file: (_a = materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url) !== null && _a !== void 0 ? _a : '',
35
+ title: materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.title,
36
+ cMapUrl: cMapUrl,
37
+ hasError: !(materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url) || materialPdfStatus === 'rejected',
38
+ i18n: {
39
+ fullscreen: intl.formatMessage({
40
+ id: 'pdf.fullScreen'
41
+ }),
42
+ download: intl.formatMessage({
43
+ id: 'pdf.download'
44
+ }),
45
+ loading: intl.formatMessage({
46
+ id: 'pdf.status.loading'
47
+ }),
48
+ error: intl.formatMessage({
49
+ id: 'pdf.status.error'
50
+ })
51
+ }
52
+ });
82
53
  };
83
54
 
84
55
  exports.default = MaterialPdfContent;
@@ -0,0 +1,7 @@
1
+ export declare const en: {
2
+ 'pdf.status.loading': string;
3
+ 'pdf.status.error': string;
4
+ 'pdf.fullScreen': string;
5
+ 'pdf.download': string;
6
+ };
7
+ export declare const ko: typeof en;
@@ -0,0 +1,17 @@
1
+ 'use strict';
2
+
3
+ const en = {
4
+ 'pdf.status.loading': 'Loading File...',
5
+ 'pdf.status.error': 'Error occurred while loading file.',
6
+ 'pdf.fullScreen': 'Full Screen',
7
+ 'pdf.download': 'File download'
8
+ };
9
+ const ko = {
10
+ 'pdf.status.loading': '수업 자료 로딩 중...',
11
+ 'pdf.status.error': '수업 자료를 가져오는 중 문제가 발생하였습니다.',
12
+ 'pdf.fullScreen': '화면 맞춤',
13
+ 'pdf.download': '수업 자료 다운로드'
14
+ };
15
+
16
+ exports.en = en;
17
+ exports.ko = ko;
@@ -1,10 +1,9 @@
1
1
  import React from 'react';
2
- import type { WithIntlComponentBuilderProps } from '@elice/intl';
3
2
  export interface MaterialPdfProps {
4
3
  className?: string;
5
4
  materialPdfId: number;
6
5
  cMapUrl?: string;
7
6
  locale?: string;
8
7
  }
9
- declare const _default: React.ForwardRefExoticComponent<import("@elice/intl").IntlComponentExtraProps & Omit<WithIntlComponentBuilderProps<MaterialPdfProps>, keyof import("@elice/intl").IntlComponentExtraProps | "__intl"> & React.RefAttributes<any>>;
10
- export default _default;
8
+ declare const MaterialPdf: React.FC<MaterialPdfProps>;
9
+ export default MaterialPdf;
@@ -1,31 +1,31 @@
1
- import { jsx } from 'react/jsx-runtime';
2
- import { IntlComponentBuilder, RawEliceIntlProvider } from '@elice/intl';
1
+ import React from 'react';
2
+ import { IntlProvider } from 'react-intl';
3
3
  import classnames from 'classnames';
4
- import messageEn from './locales/en.json.js';
5
- import messageKo from './locales/ko.json.js';
4
+ import * as locales from './locales.js';
5
+ import { en } from './locales.js';
6
6
  import MaterialPdfContent from './MaterialPdfContent.js';
7
7
  import { StyledMaterialPdfWrapper } from './MaterialPdf.styled.js';
8
8
 
9
- var MaterialPdf = function MaterialPdf(_ref) {
10
- var className = _ref.className,
11
- materialPdfId = _ref.materialPdfId,
12
- cMapUrl = _ref.cMapUrl,
13
- __intl = _ref.__intl;
14
- var prefixCls = 'em-material-pdf';
9
+ const MaterialPdf = ({
10
+ className,
11
+ materialPdfId,
12
+ cMapUrl,
13
+ locale = 'en'
14
+ }) => {
15
+ const prefixCls = 'em-material-pdf';
15
16
  //
16
17
  //
17
18
  //
18
- return jsx(RawEliceIntlProvider, {
19
- value: __intl,
20
- children: jsx(StyledMaterialPdfWrapper, {
21
- className: classnames(prefixCls, className),
22
- children: jsx(MaterialPdfContent, {
23
- materialPdfId: materialPdfId,
24
- cMapUrl: cMapUrl
25
- })
26
- })
27
- });
19
+ return React.createElement(StyledMaterialPdfWrapper, {
20
+ className: classnames(prefixCls, className)
21
+ }, React.createElement(IntlProvider, {
22
+ locale: locale,
23
+ defaultLocale: "en",
24
+ messages: locale in locales ? locales[locale] : en
25
+ }, React.createElement(MaterialPdfContent, {
26
+ materialPdfId: materialPdfId,
27
+ cMapUrl: cMapUrl
28
+ })));
28
29
  };
29
- var MaterialPdf$1 = new IntlComponentBuilder(MaterialPdf).add('en', messageEn).add('ko', messageKo).addAsync('th', import('./locales/th.json.js')).addAsync('ja', import('./locales/ja.json.js')).build();
30
30
 
31
- export { MaterialPdf$1 as default };
31
+ export { MaterialPdf as default };
@@ -1,7 +1,7 @@
1
1
  import styled from 'styled-components';
2
2
 
3
- var StyledMaterialPdfWrapper = styled.div.withConfig({
3
+ const StyledMaterialPdfWrapper = styled.div.withConfig({
4
4
  componentId: "sc-hovq54-0"
5
- })(["margin:0;flex:2 1;width:100%;height:100%;overflow:hidden;background-color:#22222c;"]);
5
+ })(["margin:0;flex:2 1;height:100%;background-color:#22222c;"]);
6
6
 
7
7
  export { StyledMaterialPdfWrapper };
@@ -1,76 +1,51 @@
1
- import { jsx } from 'react/jsx-runtime';
2
- import React, { useMemo } from 'react';
1
+ import React from 'react';
2
+ import { useIntl } from 'react-intl';
3
3
  import { getOrgMaterialPdfGet, config } from '@elice/api-client';
4
- import { Spinner, DocumentRenderer } from '@elice/blocks';
5
- import { useRawEliceIntl } from '@elice/intl';
4
+ import { Spinner, PdfRenderer } from '@elice/blocks';
6
5
  import { useMaterialFetch } from '@elice/material-shared-utils';
7
6
  import { enums } from '@elice/types';
8
7
 
9
8
  //
10
9
  //
11
10
  //
12
- var POWERPOINT_EXTENSIONS = ['ppt', 'pptx', 'pps', 'ppsx'];
13
- var MaterialPdfContent = function MaterialPdfContent(_ref) {
14
- var materialPdfId = _ref.materialPdfId,
15
- cMapUrl = _ref.cMapUrl;
16
- var intl = useRawEliceIntl();
17
- var _useMaterialFetch = useMaterialFetch(enums.LectureMaterialType.PDF, React.useCallback(function (signal) {
18
- return getOrgMaterialPdfGet({
19
- materialPdfId: materialPdfId
20
- }, {
21
- signal: signal
22
- });
23
- }, [materialPdfId]), config.init),
24
- materialPdf = _useMaterialFetch.materialPdf,
25
- materialPdfStatus = _useMaterialFetch.status;
26
- var isPowerPointFile = useMemo(function () {
27
- var _a, _b;
28
- if (!(materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url)) return false;
29
- var _URL = new URL(materialPdf.attachment.url),
30
- pathname = _URL.pathname;
31
- var currentFileName = (_a = pathname.split('/').pop()) !== null && _a !== void 0 ? _a : '';
32
- var currentFileExtension = (_b = currentFileName.split('.').pop()) !== null && _b !== void 0 ? _b : '';
33
- return POWERPOINT_EXTENSIONS.some(function (extension) {
34
- return currentFileExtension.toLowerCase().includes(extension);
35
- });
36
- }, [materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url]);
37
- var componentProps = useMemo(function () {
38
- var _a;
39
- return isPowerPointFile ? {
40
- type: 'powerpoint',
41
- src: materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url,
42
- i18n: {
43
- error: intl.formatMessage({
44
- id: 'pdf.status.error'
45
- })
46
- }
47
- } : {
48
- type: 'pdf',
49
- key: materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url,
50
- file: (_a = materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url) !== null && _a !== void 0 ? _a : '',
51
- title: materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.title,
52
- cMapUrl: cMapUrl,
53
- hasError: !(materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url) || materialPdfStatus === 'rejected',
54
- i18n: {
55
- fullscreen: intl.formatMessage({
56
- id: 'pdf.fullScreen'
57
- }),
58
- download: intl.formatMessage({
59
- id: 'pdf.download'
60
- }),
61
- loading: intl.formatMessage({
62
- id: 'pdf.status.loading'
63
- }),
64
- error: intl.formatMessage({
65
- id: 'pdf.status.error'
66
- })
67
- }
68
- };
69
- }, [cMapUrl, intl, isPowerPointFile, materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url, materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.title, materialPdfStatus]);
11
+ const MaterialPdfContent = ({
12
+ materialPdfId,
13
+ cMapUrl
14
+ }) => {
15
+ var _a;
16
+ const intl = useIntl();
17
+ const {
18
+ materialPdf,
19
+ status: materialPdfStatus
20
+ } = useMaterialFetch(enums.LectureMaterialType.PDF, React.useCallback(signal => getOrgMaterialPdfGet({
21
+ materialPdfId
22
+ }, {
23
+ signal
24
+ }), [materialPdfId]), config.init);
70
25
  if (materialPdfStatus === 'pending') {
71
- return jsx(Spinner, {});
26
+ return React.createElement(Spinner, null);
72
27
  }
73
- return jsx(DocumentRenderer, Object.assign({}, componentProps));
28
+ return React.createElement(PdfRenderer, {
29
+ key: materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url,
30
+ file: (_a = materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url) !== null && _a !== void 0 ? _a : '',
31
+ title: materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.title,
32
+ cMapUrl: cMapUrl,
33
+ hasError: !(materialPdf === null || materialPdf === void 0 ? void 0 : materialPdf.attachment.url) || materialPdfStatus === 'rejected',
34
+ i18n: {
35
+ fullscreen: intl.formatMessage({
36
+ id: 'pdf.fullScreen'
37
+ }),
38
+ download: intl.formatMessage({
39
+ id: 'pdf.download'
40
+ }),
41
+ loading: intl.formatMessage({
42
+ id: 'pdf.status.loading'
43
+ }),
44
+ error: intl.formatMessage({
45
+ id: 'pdf.status.error'
46
+ })
47
+ }
48
+ });
74
49
  };
75
50
 
76
51
  export { MaterialPdfContent as default };
@@ -0,0 +1,7 @@
1
+ export declare const en: {
2
+ 'pdf.status.loading': string;
3
+ 'pdf.status.error': string;
4
+ 'pdf.fullScreen': string;
5
+ 'pdf.download': string;
6
+ };
7
+ export declare const ko: typeof en;
@@ -0,0 +1,14 @@
1
+ const en = {
2
+ 'pdf.status.loading': 'Loading File...',
3
+ 'pdf.status.error': 'Error occurred while loading file.',
4
+ 'pdf.fullScreen': 'Full Screen',
5
+ 'pdf.download': 'File download'
6
+ };
7
+ const ko = {
8
+ 'pdf.status.loading': '수업 자료 로딩 중...',
9
+ 'pdf.status.error': '수업 자료를 가져오는 중 문제가 발생하였습니다.',
10
+ 'pdf.fullScreen': '화면 맞춤',
11
+ 'pdf.download': '수업 자료 다운로드'
12
+ };
13
+
14
+ export { en, ko };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elice/material-pdf",
3
- "version": "1.240306.0-runboxtutoring.0",
3
+ "version": "1.240306.0",
4
4
  "description": "User view and editing components of Elice material PDF",
5
5
  "repository": "https://git.elicer.io/elice/frontend/library/elice-material",
6
6
  "license": "UNLICENSED",
@@ -17,8 +17,10 @@
17
17
  "scripts": {
18
18
  "start": "run-s watch",
19
19
  "prebuild": "run-s clean",
20
- "build": "cross-env NODE_ENV=production rollup -c ../../rollup.config.ts --configPlugin typescript -f es -f cjs",
21
- "watch": "rollup -c ../../rollup.config.ts --configPlugin typescript -f es -f cjs -w",
20
+ "build": "run-p build:es build:cjs",
21
+ "build:es": "rollup -c ../../rollup.config.ts --configPlugin typescript -f es",
22
+ "build:cjs": "rollup -c ../../rollup.config.ts --configPlugin typescript -f cjs",
23
+ "watch": "rollup -c ../../rollup.config.ts --configPlugin typescript -f es -w",
22
24
  "lint": "eslint --ext .ts,.tsx ./src --max-warnings=0",
23
25
  "clean": "del-cli \"es/*\" \"cjs/*\" \"dist/*\""
24
26
  },
@@ -27,12 +29,12 @@
27
29
  "@elice/blocks": "^1",
28
30
  "@elice/design-tokens": "^1",
29
31
  "@elice/icons": "^1",
30
- "@elice/intl": "^0",
31
32
  "@elice/markdown": "^1",
32
33
  "@elice/material-shared-types": "*",
33
34
  "@elice/material-shared-utils": "*",
34
35
  "@elice/types": "^1",
35
36
  "react": "^16.8.0 || ^17.0.0 || ^18.0.0",
37
+ "react-intl": "^5.0.0",
36
38
  "react-use": "^17.0.0",
37
39
  "styled-components": "^5.2.0"
38
40
  },
@@ -41,21 +43,22 @@
41
43
  "tslib": "^2.6.1"
42
44
  },
43
45
  "devDependencies": {
44
- "@elice/api-client": "^1.241220.0",
45
- "@elice/blocks": "1.241007.0",
46
+ "@elice/api-client": "^1.230815.0",
47
+ "@elice/blocks": "^1.230816.0",
46
48
  "@elice/design-tokens": "^1.220803.0",
47
49
  "@elice/icons": "^1.230814.0",
48
50
  "@elice/icons-legacy": "npm:@elice/icons@0.230814.0",
49
- "@elice/intl": "0.241127.0",
50
- "@elice/markdown": "1.241015.0",
51
- "@elice/material-shared-types": "1.240306.0-runboxtutoring.0",
52
- "@elice/material-shared-utils": "1.240306.0-runboxtutoring.0",
53
- "@elice/types": "1.241220.0",
51
+ "@elice/markdown": "^1.220815.0",
52
+ "@elice/material-shared-types": "1.240306.0",
53
+ "@elice/material-shared-utils": "1.240306.0",
54
+ "@elice/types": "^1.240208.0",
54
55
  "@types/classnames": "^2.3.1",
55
56
  "@types/react": "~17.0.9",
56
57
  "@types/styled-components": "^5.1.21",
57
58
  "react": "^17.0.2",
59
+ "react-intl": "^5.20.10",
58
60
  "react-use": "^17.2.4",
59
61
  "styled-components": "^5.3.0"
60
- }
62
+ },
63
+ "gitHead": "c60a4ee0a90459f286596540aa4ac53240c21f7c"
61
64
  }
@@ -1,7 +0,0 @@
1
- 'use strict';
2
-
3
- var MaterialPdf = require('./MaterialPdf.js');
4
-
5
-
6
-
7
- exports.MaterialPdf = MaterialPdf.default;
@@ -1,7 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var messageEn = {"pdf.status.loading":"Loading File...","pdf.status.error":"Error occurred while loading file.","pdf.fullScreen":"Full Screen","pdf.download":"File download"};
6
-
7
- exports.default = messageEn;
@@ -1,4 +0,0 @@
1
- export { default as messageEn } from './en.json';
2
- export { default as messageKo } from './ko.json';
3
- export { default as messageTh } from './th.json';
4
- export { default as messageJa } from './ja.json';
@@ -1,13 +0,0 @@
1
- 'use strict';
2
-
3
- var en = require('./en.json.js');
4
- var ko = require('./ko.json.js');
5
- var th = require('./th.json.js');
6
- var ja = require('./ja.json.js');
7
-
8
-
9
-
10
- exports.messageEn = en.default;
11
- exports.messageKo = ko.default;
12
- exports.messageTh = th.default;
13
- exports.messageJa = ja.default;
@@ -1,7 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var ja = {"pdf.status.loading":"ファイルを読み込んでいます...","pdf.status.error":"ファイルの読み込み中にエラーが発生しました。","pdf.fullScreen":"フルスクリーン","pdf.download":"ファイルのダウンロード"};
6
-
7
- exports.default = ja;
@@ -1,7 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var messageKo = {"pdf.status.loading":"{_termLibraryLecture} {_termLibraryLecturePage} 로딩 중...","pdf.status.error":"{_termLibraryLecture} {_termLibraryLecturePage}를 가져오는 중 문제가 발생하였습니다.","pdf.fullScreen":"화면 맞춤","pdf.download":"{_termLibraryLecture} {_termLibraryLecturePage} 다운로드"};
6
-
7
- exports.default = messageKo;
@@ -1,7 +0,0 @@
1
- 'use strict';
2
-
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- var th = {"pdf.status.loading":"{_termLibraryLecture} {_termLibraryLecturePage} กำลังโหลด...","pdf.status.error":"เกิดข้อผิดพลาดในการดึงข้อมูล {_termLibraryLecture} {_termLibraryLecturePage}","pdf.fullScreen":"เต็มหน้าจอ","pdf.download":"ดาวน์โหลด {_termLibraryLecture} {_termLibraryLecturePage}"};
6
-
7
- exports.default = th;
@@ -1 +0,0 @@
1
- export { default as MaterialPdf } from './MaterialPdf.js';
@@ -1,3 +0,0 @@
1
- var messageEn = {"pdf.status.loading":"Loading File...","pdf.status.error":"Error occurred while loading file.","pdf.fullScreen":"Full Screen","pdf.download":"File download"};
2
-
3
- export { messageEn as default };
@@ -1,4 +0,0 @@
1
- export { default as messageEn } from './en.json';
2
- export { default as messageKo } from './ko.json';
3
- export { default as messageTh } from './th.json';
4
- export { default as messageJa } from './ja.json';
@@ -1,4 +0,0 @@
1
- export { default as messageEn } from './en.json.js';
2
- export { default as messageKo } from './ko.json.js';
3
- export { default as messageTh } from './th.json.js';
4
- export { default as messageJa } from './ja.json.js';
@@ -1,3 +0,0 @@
1
- var ja = {"pdf.status.loading":"ファイルを読み込んでいます...","pdf.status.error":"ファイルの読み込み中にエラーが発生しました。","pdf.fullScreen":"フルスクリーン","pdf.download":"ファイルのダウンロード"};
2
-
3
- export { ja as default };
@@ -1,3 +0,0 @@
1
- var messageKo = {"pdf.status.loading":"{_termLibraryLecture} {_termLibraryLecturePage} 로딩 중...","pdf.status.error":"{_termLibraryLecture} {_termLibraryLecturePage}를 가져오는 중 문제가 발생하였습니다.","pdf.fullScreen":"화면 맞춤","pdf.download":"{_termLibraryLecture} {_termLibraryLecturePage} 다운로드"};
2
-
3
- export { messageKo as default };
@@ -1,3 +0,0 @@
1
- var th = {"pdf.status.loading":"{_termLibraryLecture} {_termLibraryLecturePage} กำลังโหลด...","pdf.status.error":"เกิดข้อผิดพลาดในการดึงข้อมูล {_termLibraryLecture} {_termLibraryLecturePage}","pdf.fullScreen":"เต็มหน้าจอ","pdf.download":"ดาวน์โหลด {_termLibraryLecture} {_termLibraryLecturePage}"};
2
-
3
- export { th as default };