@lotte-innovate/ui-component-test 0.2.54 → 0.2.55

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,6 +1,7 @@
1
1
  import React from 'react';
2
2
  import { IAllProps } from '@tinymce/tinymce-react';
3
3
  import { VariantProps } from 'class-variance-authority';
4
+ import 'tinymce/skins/ui/oxide/skin.css';
4
5
  export interface EditorProps extends VariantProps<typeof editorVariants> {
5
6
  }
6
7
  declare const editorVariants: (props?: ({
@@ -29,13 +29,16 @@ import { loadTinyMCE } from '../../../lib/utils/useLoadTinyMCE';
29
29
  import { scalingVariants } from '../../../lib/constants';
30
30
  import { cn } from '../../../lib/utils/utils';
31
31
  import { marked } from 'marked';
32
+ import 'tinymce/skins/ui/oxide/skin.css';
33
+ import contentUiSkinCss from '!!raw-loader!tinymce/skins/ui/oxide/content.css';
34
+ import contentCss from '!!raw-loader!tinymce/skins/content/default/content.css';
32
35
  var editorVariants = cva('', {
33
36
  variants: {
34
37
  scaling: __assign({}, scalingVariants),
35
38
  size: {
36
- small: 'w-[500px] h-[350px]',
37
- medium: 'w-[550px] h-[400px]',
38
- large: 'w-[600px] h-[450px]',
39
+ small: 'w-[650px] h-[350px]',
40
+ medium: 'w-[700px] h-[400px]',
41
+ large: 'w-[750px] h-[450px]',
39
42
  },
40
43
  },
41
44
  defaultVariants: {
@@ -56,7 +59,7 @@ export var Editor = forwardRef(function (_a, ref) {
56
59
  if (!isClient) {
57
60
  return null;
58
61
  }
59
- return (_jsx("div", { className: cn(editorVariants({ size: size, scaling: scaling }), className), ref: ref, children: _jsx(EditorUI, __assign({ init: __assign({ base_url: 'tinymce', width: '100%', height: '100%', promotion: false, plugins: 'preview importcss searchreplace autolink autosave save directionality code visualblocks visualchars fullscreen image link media template codesample table charmap pagebreak nonbreaking anchor insertdatetime advlist lists wordcount charmap accordion', menubar: 'file edit view insert format tools table', toolbar: 'undo redo | accordion accordionremove | blocks fontfamily fontsize | bold italic underline strikethrough | align numlist bullist | link image | table media | lineheight outdent indent| forecolor backcolor removeformat | charmap | code fullscreen preview | save print | pagebreak anchor codesample | ltr rtl', autosave_ask_before_unload: true, autosave_interval: '30s', autosave_restore_when_empty: false, autosave_retention: '2m', image_advtab: true, image_caption: true, quickbars_selection_toolbar: '', toolbar_mode: 'sliding', content_style: 'body { font-family:Noto Sans KR, sans-serif, Nunito Sans, Helvetica Neue, Helvetica }', setup: function (editor) {
62
+ return (_jsx("div", { className: cn(editorVariants({ size: size, scaling: scaling }), className), ref: ref, children: _jsx(EditorUI, __assign({ init: __assign({ width: '100%', height: '100%', promotion: false, plugins: 'preview importcss searchreplace autolink autosave save directionality code visualblocks visualchars fullscreen image link media template codesample table charmap pagebreak nonbreaking anchor insertdatetime advlist lists wordcount charmap accordion', menubar: 'file edit view insert format tools table', toolbar: 'undo redo | accordion accordionremove | blocks fontfamily fontsize | bold italic underline strikethrough | align numlist bullist | link image | table media | lineheight outdent indent| forecolor backcolor removeformat | charmap | code fullscreen preview | save print | pagebreak anchor codesample | ltr rtl', autosave_ask_before_unload: true, autosave_interval: '30s', autosave_restore_when_empty: false, autosave_retention: '2m', image_advtab: true, image_caption: true, quickbars_selection_toolbar: '', toolbar_mode: 'sliding', skin: false, content_css: false, content_style: "".concat(contentUiSkinCss, "\n").concat(contentCss, "\n body { font-family:Noto Sans KR, sans-serif, Nunito Sans, Helvetica Neue, Helvetica }"), setup: function (editor) {
60
63
  editor.ui.registry.addButton('inlinecode', {
61
64
  icon: 'sourcecode',
62
65
  tooltip: 'Inline code',
@@ -1,3 +1,3 @@
1
1
  "use client";
2
- import{jsx as e}from"react/jsx-runtime";import{forwardRef as t,useState as o,useEffect as i}from"react";import{Editor as n}from"@tinymce/tinymce-react";import{cva as a}from"class-variance-authority";import{loadTinyMCE as r}from"../../utils/useLoadTinyMCE.mjs";import{scalingVariants as l}from"../../constants.mjs";import{cn as s}from"../../utils/utils.mjs";import{marked as c}from"marked";var m=function(){return m=Object.assign||function(e){for(var t,o=1,i=arguments.length;o<i;o++)for(var n in t=arguments[o])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},m.apply(this,arguments)},u=function(e,t){var o={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(o[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(i=Object.getOwnPropertySymbols(e);n<i.length;n++)t.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(o[i[n]]=e[i[n]])}return o},d=a("",{variants:{scaling:m({},l),size:{small:"w-[500px] h-[350px]",medium:"w-[550px] h-[400px]",large:"w-[600px] h-[450px]"}},defaultVariants:{scaling:"100%",size:"medium"}}),p=t((function(t,a){var l=t.className,p=t.size,f=t.scaling,v=t.init,g=u(t,["className","size","scaling","init"]),b=o(!1),y=b[0],h=b[1];return i((function(){"undefined"!=typeof window&&r().then((function(){h(!0)}))}),[]),y?e("div",{className:s(d({size:p,scaling:f}),l),ref:a,children:e(n,m({init:m({base_url:"tinymce",width:"100%",height:"100%",promotion:!1,plugins:"preview importcss searchreplace autolink autosave save directionality code visualblocks visualchars fullscreen image link media template codesample table charmap pagebreak nonbreaking anchor insertdatetime advlist lists wordcount charmap accordion",menubar:"file edit view insert format tools table",toolbar:"undo redo | accordion accordionremove | blocks fontfamily fontsize | bold italic underline strikethrough | align numlist bullist | link image | table media | lineheight outdent indent| forecolor backcolor removeformat | charmap | code fullscreen preview | save print | pagebreak anchor codesample | ltr rtl",autosave_ask_before_unload:!0,autosave_interval:"30s",autosave_restore_when_empty:!1,autosave_retention:"2m",image_advtab:!0,image_caption:!0,quickbars_selection_toolbar:"",toolbar_mode:"sliding",content_style:"body { font-family:Noto Sans KR, sans-serif, Nunito Sans, Helvetica Neue, Helvetica }",setup:function(e){e.ui.registry.addButton("inlinecode",{icon:"sourcecode",tooltip:"Inline code",onAction:function(){e.formatter.toggle("code")}}),e.on("init",(function(){e.formatter.register("code",{inline:"code",remove:"all"})})),e.ui.registry.addButton("markdown",{text:"Markdown",onAction:function(){var t=e.getContent({format:"text"}),o=c(t);e.setContent(o)}})}},v)},g))}):null}));p.displayName="Editor";export{p as Editor,p as default};
2
+ import{jsx as e}from"react/jsx-runtime";import{forwardRef as t,useState as o,useEffect as i}from"react";import{Editor as n}from"@tinymce/tinymce-react";import{cva as r}from"class-variance-authority";import{loadTinyMCE as a}from"../../utils/useLoadTinyMCE.mjs";import{scalingVariants as s}from"../../constants.mjs";import{cn as c}from"../../utils/utils.mjs";import{marked as l}from"marked";import"tinymce/skins/ui/oxide/skin.css";import m from"!!raw-loader!tinymce/skins/ui/oxide/content.css";import u from"!!raw-loader!tinymce/skins/content/default/content.css";var d=function(){return d=Object.assign||function(e){for(var t,o=1,i=arguments.length;o<i;o++)for(var n in t=arguments[o])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},d.apply(this,arguments)},p=function(e,t){var o={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(o[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(i=Object.getOwnPropertySymbols(e);n<i.length;n++)t.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(o[i[n]]=e[i[n]])}return o},f=r("",{variants:{scaling:d({},s),size:{small:"w-[650px] h-[350px]",medium:"w-[700px] h-[400px]",large:"w-[750px] h-[450px]"}},defaultVariants:{scaling:"100%",size:"medium"}}),v=t((function(t,r){var s=t.className,v=t.size,g=t.scaling,y=t.init,b=p(t,["className","size","scaling","init"]),h=o(!1),k=h[0],w=h[1];return i((function(){"undefined"!=typeof window&&a().then((function(){w(!0)}))}),[]),k?e("div",{className:c(f({size:v,scaling:g}),s),ref:r,children:e(n,d({init:d({width:"100%",height:"100%",promotion:!1,plugins:"preview importcss searchreplace autolink autosave save directionality code visualblocks visualchars fullscreen image link media template codesample table charmap pagebreak nonbreaking anchor insertdatetime advlist lists wordcount charmap accordion",menubar:"file edit view insert format tools table",toolbar:"undo redo | accordion accordionremove | blocks fontfamily fontsize | bold italic underline strikethrough | align numlist bullist | link image | table media | lineheight outdent indent| forecolor backcolor removeformat | charmap | code fullscreen preview | save print | pagebreak anchor codesample | ltr rtl",autosave_ask_before_unload:!0,autosave_interval:"30s",autosave_restore_when_empty:!1,autosave_retention:"2m",image_advtab:!0,image_caption:!0,quickbars_selection_toolbar:"",toolbar_mode:"sliding",skin:!1,content_css:!1,content_style:"".concat(m,"\n").concat(u,"\n body { font-family:Noto Sans KR, sans-serif, Nunito Sans, Helvetica Neue, Helvetica }"),setup:function(e){e.ui.registry.addButton("inlinecode",{icon:"sourcecode",tooltip:"Inline code",onAction:function(){e.formatter.toggle("code")}}),e.on("init",(function(){e.formatter.register("code",{inline:"code",remove:"all"})})),e.ui.registry.addButton("markdown",{text:"Markdown",onAction:function(){var t=e.getContent({format:"text"}),o=l(t);e.setContent(o)}})}},y)},b))}):null}));v.displayName="Editor";export{v as Editor,v as default};
3
3
  //# sourceMappingURL=index.mjs.map