intlayer-editor 8.4.2 → 8.4.4
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/client/dist/assets/{CodeBlockShiki-BQ0Urv39.js → CodeBlockShiki-DWls2qRj.js} +14 -14
- package/client/dist/assets/{angular-html-B40pL6wl.js → angular-html-B6JGjnhw.js} +2 -2
- package/client/dist/assets/{angular-ts-DEfIxZMp.js → angular-ts-C0LZhPn3.js} +2 -2
- package/client/dist/assets/{astro-DDXXh1_1.js → astro-DRhNdJ7D.js} +5 -5
- package/client/dist/assets/bash-BDj1ZMbF.js +2 -0
- package/client/dist/assets/{blade-BqWGpLk3.js → blade-CmblGiYC.js} +7 -7
- package/client/dist/assets/{bundle-web-CQgz7w95.js → bundle-web-Cg9hBSjQ.js} +42 -42
- package/client/dist/assets/{c-rYJZrW1k.js → c-BP1HALHq.js} +1 -1
- package/client/dist/assets/{chunk-CC9Q-vWm.js → chunk-C0u3WHrm.js} +1 -5
- package/client/dist/assets/{coffee-B7kx3Cid.js → coffee-C28B5GV0.js} +1 -1
- package/client/dist/assets/{cpp-3L9-cBo7.js → cpp-Cidd5v6X.js} +3 -3
- package/client/dist/assets/{css-BznhwoPH.js → css-DirbBcKV.js} +1 -1
- package/client/dist/assets/{dist-JL9Mfqir.js → dist-DV8htl3g.js} +2 -2
- package/client/dist/assets/{glsl-D7GhljHe.js → glsl-DoqwcQRt.js} +2 -2
- package/client/dist/assets/{graphql-CFwfqi3h.js → graphql-Dk8PWT7j.js} +4 -4
- package/client/dist/assets/{haml-AGy9GVVj.js → haml-66_uT442.js} +2 -2
- package/client/dist/assets/{handlebars-vOgalqpV.js → handlebars-BSuqha3R.js} +3 -3
- package/client/dist/assets/{html-B0M7Ubrz.js → html-CR2zuqaP.js} +3 -3
- package/client/dist/assets/html-C_WOzrgj.js +2 -0
- package/client/dist/assets/{html-derivative-B7ZIKlQ2.js → html-derivative-Cclou0aP.js} +2 -2
- package/client/dist/assets/{http-Bw1SWifZ.js → http-Chfri83B.js} +4 -4
- package/client/dist/assets/{hurl-zcy5Fl2y.js → hurl-CJYG0qEj.js} +2 -2
- package/client/dist/assets/{index-DT2mmysE.js → index-1h009QuF.js} +615 -775
- package/client/dist/assets/{java-BsMRZzwb.js → java-B8PDrwgp.js} +1 -1
- package/client/dist/assets/javascript-DnideQC4.js +2 -0
- package/client/dist/assets/{javascript-CU3PIJIe.js → javascript-gbo83QZh.js} +1 -1
- package/client/dist/assets/{jinja-CpV-HaFu.js → jinja-DjrurZ3w.js} +1 -1
- package/client/dist/assets/{jison-DaIhV8hg.js → jison-Bzb7AiNT.js} +1 -1
- package/client/dist/assets/json-BqbkG0mH.js +2 -0
- package/client/dist/assets/{json-NRUJ3A8Z.js → json-CunY19G8.js} +1 -1
- package/client/dist/assets/{jsx-D27Zcp8f.js → jsx-DKpAzk1L.js} +1 -1
- package/client/dist/assets/{julia-BwktqeJq.js → julia-Bb9EanCZ.js} +3 -3
- package/client/dist/assets/{marko-DZhB4BDZ.js → marko-BMBjaKAA.js} +3 -3
- package/client/dist/assets/{mdc-ByFPmJVb.js → mdc-DHml8znM.js} +1 -1
- package/client/dist/assets/{php-Cq-zzIgW.js → php-B7g111ez.js} +6 -6
- package/client/dist/assets/{pug-BqsC6HRi.js → pug-DPA9vacE.js} +3 -3
- package/client/dist/assets/{react-BPfKr7Oj.js → react-BI_C_976.js} +1 -1
- package/client/dist/assets/{regexp-Bv54x_SM.js → regexp-C2EHb1E5.js} +1 -1
- package/client/dist/assets/{scss-BDzsPcer.js → scss-DUiSzTzo.js} +2 -2
- package/client/dist/assets/{shellscript-D6OjgcVH.js → shellscript-DkioAF_Z.js} +1 -1
- package/client/dist/assets/{sql-D1VHE84D.js → sql-Bq2TyiLf.js} +1 -1
- package/client/dist/assets/{svelte-7kInhlba.js → svelte-B4a91jKy.js} +3 -3
- package/client/dist/assets/{ts-tags-CmxNgKEj.js → ts-tags-CmAHPpbA.js} +7 -7
- package/client/dist/assets/tsx-COT10Yhw.js +2 -0
- package/client/dist/assets/{tsx-CzwR-tnf.js → tsx-DhiHjC8E.js} +1 -1
- package/client/dist/assets/{typescript-BRHrOBpy.js → typescript-DIknz8xV.js} +1 -1
- package/client/dist/assets/typescript-DVn5xcxs.js +2 -0
- package/client/dist/assets/vue-DMs-rpfR.js +2 -0
- package/client/dist/assets/{vue-CG7sAwHH.js → vue-DSQFQ9Fa.js} +6 -6
- package/client/dist/assets/{vue-html-DHRq-ZD1.js → vue-html-CPPbLqF0.js} +1 -1
- package/client/dist/assets/{vue-vine-BAAyauNs.js → vue-vine-BolHA4m8.js} +3 -3
- package/client/dist/assets/{xml-CPgLmR05.js → xml-BJ26UNLC.js} +2 -2
- package/client/dist/assets/xml-BsRPH7S0.js +2 -0
- package/client/dist/index.html +3 -3
- package/package.json +11 -11
- package/server/dist/checkPortAvailability-BJtgxTDw.cjs +60 -0
- package/server/dist/checkPortAvailability-BJtgxTDw.cjs.map +1 -0
- package/server/dist/index.cjs +7 -7
- package/server/dist/index.cjs.map +1 -1
- package/server/dist/index.mjs +5 -5
- package/server/dist/index.mjs.map +1 -1
- package/client/dist/assets/bash-Ctbhv6bB.js +0 -2
- package/client/dist/assets/html-Cla_1apk.js +0 -2
- package/client/dist/assets/javascript-BeimltzM.js +0 -2
- package/client/dist/assets/json-DPD_iq4F.js +0 -2
- package/client/dist/assets/tsx-CHlTOe14.js +0 -2
- package/client/dist/assets/typescript-B4HgavCc.js +0 -2
- package/client/dist/assets/vue-DlaU9qIx.js +0 -2
- package/client/dist/assets/xml-Bp8m4wBs.js +0 -2
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { t as javascript_default } from "./javascript-
|
|
2
|
-
import { t as css_default } from "./css-
|
|
3
|
-
import { t as html_default } from "./html-
|
|
4
|
-
import { t as json_default } from "./json-
|
|
5
|
-
import { t as typescript_default } from "./typescript-
|
|
6
|
-
import { t as html_derivative_default } from "./html-derivative-
|
|
1
|
+
import { t as javascript_default } from "./javascript-gbo83QZh.js";
|
|
2
|
+
import { t as css_default } from "./css-DirbBcKV.js";
|
|
3
|
+
import { t as html_default } from "./html-CR2zuqaP.js";
|
|
4
|
+
import { t as json_default } from "./json-CunY19G8.js";
|
|
5
|
+
import { t as typescript_default } from "./typescript-DIknz8xV.js";
|
|
6
|
+
import { t as html_derivative_default } from "./html-derivative-Cclou0aP.js";
|
|
7
7
|
var markdown_vue_default = [Object.freeze(JSON.parse("{\"fileTypes\":[],\"injectTo\":[\"text.html.markdown\"],\"injectionSelector\":\"L:text.html.markdown\",\"name\":\"markdown-vue\",\"patterns\":[{\"include\":\"#vue-code-block\"}],\"repository\":{\"vue-code-block\":{\"begin\":\"(^|\\\\G)(\\\\s*)(`{3,}|~{3,})\\\\s*(?i:(vue)((\\\\s+|[,:?{])[^`~]*)?$)\",\"beginCaptures\":{\"3\":{\"name\":\"punctuation.definition.markdown\"},\"4\":{\"name\":\"fenced_code.block.language.markdown\"},\"5\":{\"name\":\"fenced_code.block.language.attributes.markdown\",\"patterns\":[]}},\"end\":\"(^|\\\\G)(\\\\2|\\\\s{0,3})(\\\\3)\\\\s*$\",\"endCaptures\":{\"3\":{\"name\":\"punctuation.definition.markdown\"}},\"name\":\"markup.fenced_code.block.markdown\",\"patterns\":[{\"include\":\"text.html.vue\"}]}},\"scopeName\":\"markdown.vue.codeblock\"}"))];
|
|
8
8
|
var vue_directives_default = [Object.freeze(JSON.parse("{\"fileTypes\":[],\"injectTo\":[\"source.vue\",\"text.html.markdown\",\"text.html.derivative\",\"text.pug\"],\"injectionSelector\":\"L:meta.tag -meta.attribute -meta.ng-binding -entity.name.tag.pug -attribute_value -source.tsx -source.js.jsx, L:meta.element -meta.attribute\",\"name\":\"vue-directives\",\"patterns\":[{\"include\":\"text.html.vue#vue-directives\"}],\"scopeName\":\"vue.directives\"}"))];
|
|
9
9
|
var vue_interpolations_default = [Object.freeze(JSON.parse("{\"fileTypes\":[],\"injectTo\":[\"source.vue\",\"text.html.markdown\",\"text.html.derivative\",\"text.pug\"],\"injectionSelector\":\"L:text.pug -comment -string.comment, L:text.html.derivative -comment.block, L:text.html.markdown -comment.block\",\"name\":\"vue-interpolations\",\"patterns\":[{\"include\":\"text.html.vue#vue-interpolations\"}],\"scopeName\":\"vue.interpolations\"}"))];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as javascript_default } from "./javascript-
|
|
1
|
+
import { t as javascript_default } from "./javascript-gbo83QZh.js";
|
|
2
2
|
//#region ../../node_modules/.bun/@shikijs+langs@4.0.2/node_modules/@shikijs/langs/dist/vue-html.mjs
|
|
3
3
|
var lang = Object.freeze(JSON.parse("{\"displayName\":\"Vue HTML\",\"fileTypes\":[],\"name\":\"vue-html\",\"patterns\":[{\"include\":\"source.vue#vue-interpolations\"},{\"begin\":\"(<)([A-Z][-0-:A-Za-z]*)(?=[^>]*></\\\\2>)\",\"beginCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.begin.html\"},\"2\":{\"name\":\"support.class.component.html\"}},\"end\":\"(>)(<)(/)(\\\\2)(>)\",\"endCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.end.html\"},\"2\":{\"name\":\"punctuation.definition.tag.begin.html meta.scope.between-tag-pair.html\"},\"3\":{\"name\":\"punctuation.definition.tag.begin.html\"},\"4\":{\"name\":\"support.class.component.html\"},\"5\":{\"name\":\"punctuation.definition.tag.end.html\"}},\"name\":\"meta.tag.any.html\",\"patterns\":[{\"include\":\"#tag-stuff\"}]},{\"begin\":\"(<)([a-z][-0-:A-Za-z]*)(?=[^>]*></\\\\2>)\",\"beginCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.begin.html\"},\"2\":{\"name\":\"entity.name.tag.html\"}},\"end\":\"(>)(<)(/)(\\\\2)(>)\",\"endCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.end.html\"},\"2\":{\"name\":\"punctuation.definition.tag.begin.html meta.scope.between-tag-pair.html\"},\"3\":{\"name\":\"punctuation.definition.tag.begin.html\"},\"4\":{\"name\":\"entity.name.tag.html\"},\"5\":{\"name\":\"punctuation.definition.tag.end.html\"}},\"name\":\"meta.tag.any.html\",\"patterns\":[{\"include\":\"#tag-stuff\"}]},{\"begin\":\"(<\\\\?)(xml)\",\"captures\":{\"1\":{\"name\":\"punctuation.definition.tag.html\"},\"2\":{\"name\":\"entity.name.tag.xml.html\"}},\"end\":\"(\\\\?>)\",\"name\":\"meta.tag.preprocessor.xml.html\",\"patterns\":[{\"include\":\"#tag-generic-attribute\"},{\"include\":\"#string-double-quoted\"},{\"include\":\"#string-single-quoted\"}]},{\"begin\":\"<!--\",\"captures\":{\"0\":{\"name\":\"punctuation.definition.comment.html\"}},\"end\":\"-->\",\"name\":\"comment.block.html\"},{\"begin\":\"<!\",\"captures\":{\"0\":{\"name\":\"punctuation.definition.tag.html\"}},\"end\":\">\",\"name\":\"meta.tag.sgml.html\",\"patterns\":[{\"begin\":\"(?i:DOCTYPE)\",\"captures\":{\"1\":{\"name\":\"entity.name.tag.doctype.html\"}},\"end\":\"(?=>)\",\"name\":\"meta.tag.sgml.doctype.html\",\"patterns\":[{\"match\":\"\\\"[^\\\">]*\\\"\",\"name\":\"string.quoted.double.doctype.identifiers-and-DTDs.html\"}]},{\"begin\":\"\\\\[CDATA\\\\[\",\"end\":\"]](?=>)\",\"name\":\"constant.other.inline-data.html\"},{\"match\":\"(\\\\s*)(?!--|>)\\\\S(\\\\s*)\",\"name\":\"invalid.illegal.bad-comments-or-CDATA.html\"}]},{\"begin\":\"(</?)([A-Z][-0-:A-Za-z]*)\\\\b\",\"beginCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.begin.html\"},\"2\":{\"name\":\"support.class.component.html\"}},\"end\":\"(>)\",\"endCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.end.html\"}},\"name\":\"meta.tag.block.any.html\",\"patterns\":[{\"include\":\"#tag-stuff\"}]},{\"begin\":\"(</?)([a-z][-0-:A-Za-z]*)\\\\b\",\"beginCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.begin.html\"},\"2\":{\"name\":\"entity.name.tag.block.any.html\"}},\"end\":\"(>)\",\"endCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.end.html\"}},\"name\":\"meta.tag.block.any.html\",\"patterns\":[{\"include\":\"#tag-stuff\"}]},{\"begin\":\"(</?)((?i:body|head|html))\\\\b\",\"captures\":{\"1\":{\"name\":\"punctuation.definition.tag.begin.html\"},\"2\":{\"name\":\"entity.name.tag.structure.any.html\"}},\"end\":\"(>)\",\"endCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.end.html\"}},\"name\":\"meta.tag.structure.any.html\",\"patterns\":[{\"include\":\"#tag-stuff\"}]},{\"begin\":\"(</?)((?i:address|blockquote|dd|div|dl|dt|fieldset|form|frame|frameset|h1|h2|h3|h4|h5|h6|iframe|noframes|object|ol|p|ul|applet|center|dir|hr|menu|pre)(?!-))\\\\b\",\"beginCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.begin.html\"},\"2\":{\"name\":\"entity.name.tag.block.any.html\"}},\"end\":\"(>)\",\"endCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.end.html\"}},\"name\":\"meta.tag.block.any.html\",\"patterns\":[{\"include\":\"#tag-stuff\"}]},{\"begin\":\"(</?)((?i:a|abbr|acronym|area|b|base|basefont|bdo|big|br|button|caption|cite|code|col|colgroup|del|dfn|em|font|head|html|i|img|input|ins|isindex|kbd|label|legend|li|link|map|meta|noscript|optgroup|option|param|[qs]|samp|script|select|small|span|strike|strong|style|sub|sup|table|tbody|td|textarea|tfoot|th|thead|title|tr|tt|u|var)(?!-))\\\\b\",\"beginCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.begin.html\"},\"2\":{\"name\":\"entity.name.tag.inline.any.html\"}},\"end\":\"(/?>)\",\"endCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.end.html\"}},\"name\":\"meta.tag.inline.any.html\",\"patterns\":[{\"include\":\"#tag-stuff\"}]},{\"begin\":\"(</?)([-0-:A-Za-z]+)\",\"beginCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.begin.html\"},\"2\":{\"name\":\"entity.name.tag.other.html\"}},\"end\":\"(/?>)\",\"endCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.end.html\"}},\"name\":\"meta.tag.other.html\",\"patterns\":[{\"include\":\"#tag-stuff\"}]},{\"include\":\"#entities\"},{\"match\":\"<>\",\"name\":\"invalid.illegal.incomplete.html\"},{\"match\":\"<\",\"name\":\"invalid.illegal.bad-angle-bracket.html\"}],\"repository\":{\"entities\":{\"patterns\":[{\"captures\":{\"1\":{\"name\":\"punctuation.definition.entity.html\"},\"3\":{\"name\":\"punctuation.definition.entity.html\"}},\"match\":\"(&)([0-9A-Za-z]+|#[0-9]+|#x\\\\h+)(;)\",\"name\":\"constant.character.entity.html\"},{\"match\":\"&\",\"name\":\"invalid.illegal.bad-ampersand.html\"}]},\"string-double-quoted\":{\"begin\":\"\\\"\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.begin.html\"}},\"end\":\"\\\"\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.end.html\"}},\"name\":\"string.quoted.double.html\",\"patterns\":[{\"include\":\"source.vue#vue-interpolations\"},{\"include\":\"#entities\"}]},\"string-single-quoted\":{\"begin\":\"'\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.begin.html\"}},\"end\":\"'\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.end.html\"}},\"name\":\"string.quoted.single.html\",\"patterns\":[{\"include\":\"source.vue#vue-interpolations\"},{\"include\":\"#entities\"}]},\"tag-generic-attribute\":{\"match\":\"(?<=[^=])\\\\b([-0-:A-Z_a-z]+)\",\"name\":\"entity.other.attribute-name.html\"},\"tag-id-attribute\":{\"begin\":\"\\\\b(id)\\\\b\\\\s*(=)\",\"captures\":{\"1\":{\"name\":\"entity.other.attribute-name.id.html\"},\"2\":{\"name\":\"punctuation.separator.key-value.html\"}},\"end\":\"(?!\\\\G)(?<=[\\\"'[^/<>\\\\s]])\",\"name\":\"meta.attribute-with-value.id.html\",\"patterns\":[{\"begin\":\"\\\"\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.begin.html\"}},\"contentName\":\"meta.toc-list.id.html\",\"end\":\"\\\"\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.end.html\"}},\"name\":\"string.quoted.double.html\",\"patterns\":[{\"include\":\"source.vue#vue-interpolations\"},{\"include\":\"#entities\"}]},{\"begin\":\"'\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.begin.html\"}},\"contentName\":\"meta.toc-list.id.html\",\"end\":\"'\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.end.html\"}},\"name\":\"string.quoted.single.html\",\"patterns\":[{\"include\":\"source.vue#vue-interpolations\"},{\"include\":\"#entities\"}]},{\"captures\":{\"0\":{\"name\":\"meta.toc-list.id.html\"}},\"match\":\"(?<==)(?:[^\\\"'/<>\\\\s]|/(?!>))+\",\"name\":\"string.unquoted.html\"}]},\"tag-stuff\":{\"patterns\":[{\"include\":\"#vue-directives\"},{\"include\":\"#tag-id-attribute\"},{\"include\":\"#tag-generic-attribute\"},{\"include\":\"#string-double-quoted\"},{\"include\":\"#string-single-quoted\"},{\"include\":\"#unquoted-attribute\"}]},\"unquoted-attribute\":{\"match\":\"(?<==)(?:[^\\\"'/<>\\\\s]|/(?!>))+\",\"name\":\"string.unquoted.html\"},\"vue-directives\":{\"begin\":\"(?:\\\\b(v-)|([#:@]))([-0-9A-Z_a-z]+)(?::([-A-Z_a-z]+))?(?:\\\\.([-A-Z_a-z]+))*\\\\s*(=)\",\"captures\":{\"1\":{\"name\":\"entity.other.attribute-name.html\"},\"2\":{\"name\":\"punctuation.separator.key-value.html\"},\"3\":{\"name\":\"entity.other.attribute-name.html\"},\"4\":{\"name\":\"entity.other.attribute-name.html\"},\"5\":{\"name\":\"entity.other.attribute-name.html\"},\"6\":{\"name\":\"punctuation.separator.key-value.html\"}},\"end\":\"(?<=[\\\"'])|(?=[<>`\\\\s])\",\"name\":\"meta.directive.vue\",\"patterns\":[{\"begin\":\"`\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.begin.html\"}},\"end\":\"`\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.end.html\"}},\"name\":\"source.directive.vue\",\"patterns\":[{\"include\":\"source.js#expression\"}]},{\"begin\":\"\\\"\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.begin.html\"}},\"end\":\"\\\"\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.end.html\"}},\"name\":\"source.directive.vue\",\"patterns\":[{\"include\":\"source.js#expression\"}]},{\"begin\":\"'\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.begin.html\"}},\"end\":\"'\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.end.html\"}},\"name\":\"source.directive.vue\",\"patterns\":[{\"include\":\"source.js#expression\"}]}]}},\"scopeName\":\"text.html.vue-html\",\"embeddedLangs\":[\"javascript\"],\"embeddedLangsLazy\":[]}"));
|
|
4
4
|
var vue_html_default = [...javascript_default, lang];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { t as javascript_default } from "./javascript-
|
|
2
|
-
import { t as css_default } from "./css-
|
|
3
|
-
import { t as scss_default } from "./scss-
|
|
1
|
+
import { t as javascript_default } from "./javascript-gbo83QZh.js";
|
|
2
|
+
import { t as css_default } from "./css-DirbBcKV.js";
|
|
3
|
+
import { t as scss_default } from "./scss-DUiSzTzo.js";
|
|
4
4
|
import postcss_default from "./postcss-cbpEYqBI.js";
|
|
5
5
|
import less_default from "./less-PRJULh4Y.js";
|
|
6
6
|
import stylus_default from "./stylus-CXea6hG4.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { r as __exportAll } from "./chunk-
|
|
2
|
-
import { t as java_default } from "./java-
|
|
1
|
+
import { r as __exportAll } from "./chunk-C0u3WHrm.js";
|
|
2
|
+
import { t as java_default } from "./java-B8PDrwgp.js";
|
|
3
3
|
//#region ../../node_modules/.bun/@shikijs+langs@4.0.2/node_modules/@shikijs/langs/dist/xml.mjs
|
|
4
4
|
var xml_exports = /* @__PURE__ */ __exportAll({ default: () => xml_default });
|
|
5
5
|
var lang = Object.freeze(JSON.parse("{\"displayName\":\"XML\",\"name\":\"xml\",\"patterns\":[{\"begin\":\"(<\\\\?)\\\\s*([-0-9A-Z_a-z]+)\",\"captures\":{\"1\":{\"name\":\"punctuation.definition.tag.xml\"},\"2\":{\"name\":\"entity.name.tag.xml\"}},\"end\":\"(\\\\?>)\",\"name\":\"meta.tag.preprocessor.xml\",\"patterns\":[{\"match\":\" ([-A-Za-z]+)\",\"name\":\"entity.other.attribute-name.xml\"},{\"include\":\"#doublequotedString\"},{\"include\":\"#singlequotedString\"}]},{\"begin\":\"(<!)(DOCTYPE)\\\\s+([:A-Z_a-z][-.0-:A-Z_a-z]*)\",\"captures\":{\"1\":{\"name\":\"punctuation.definition.tag.xml\"},\"2\":{\"name\":\"keyword.other.doctype.xml\"},\"3\":{\"name\":\"variable.language.documentroot.xml\"}},\"end\":\"\\\\s*(>)\",\"name\":\"meta.tag.sgml.doctype.xml\",\"patterns\":[{\"include\":\"#internalSubset\"}]},{\"include\":\"#comments\"},{\"begin\":\"(<)((?:([-0-9A-Z_a-z]+)(:))?([-0-:A-Z_a-z]+))(?=(\\\\s[^>]*)?></\\\\2>)\",\"beginCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.xml\"},\"2\":{\"name\":\"entity.name.tag.xml\"},\"3\":{\"name\":\"entity.name.tag.namespace.xml\"},\"4\":{\"name\":\"punctuation.separator.namespace.xml\"},\"5\":{\"name\":\"entity.name.tag.localname.xml\"}},\"end\":\"(>)(</)((?:([-0-9A-Z_a-z]+)(:))?([-0-:A-Z_a-z]+))(>)\",\"endCaptures\":{\"1\":{\"name\":\"punctuation.definition.tag.xml\"},\"2\":{\"name\":\"punctuation.definition.tag.xml\"},\"3\":{\"name\":\"entity.name.tag.xml\"},\"4\":{\"name\":\"entity.name.tag.namespace.xml\"},\"5\":{\"name\":\"punctuation.separator.namespace.xml\"},\"6\":{\"name\":\"entity.name.tag.localname.xml\"},\"7\":{\"name\":\"punctuation.definition.tag.xml\"}},\"name\":\"meta.tag.no-content.xml\",\"patterns\":[{\"include\":\"#tagStuff\"}]},{\"begin\":\"(</?)(?:([-.\\\\w]+)((:)))?([-.:\\\\w]+)\",\"captures\":{\"1\":{\"name\":\"punctuation.definition.tag.xml\"},\"2\":{\"name\":\"entity.name.tag.namespace.xml\"},\"3\":{\"name\":\"entity.name.tag.xml\"},\"4\":{\"name\":\"punctuation.separator.namespace.xml\"},\"5\":{\"name\":\"entity.name.tag.localname.xml\"}},\"end\":\"(/?>)\",\"name\":\"meta.tag.xml\",\"patterns\":[{\"include\":\"#tagStuff\"}]},{\"include\":\"#entity\"},{\"include\":\"#bare-ampersand\"},{\"begin\":\"<%@\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.section.embedded.begin.xml\"}},\"end\":\"%>\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.section.embedded.end.xml\"}},\"name\":\"source.java-props.embedded.xml\",\"patterns\":[{\"match\":\"page|include|taglib\",\"name\":\"keyword.other.page-props.xml\"}]},{\"begin\":\"<%[!=]?(?!--)\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.section.embedded.begin.xml\"}},\"end\":\"(?!--)%>\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.section.embedded.end.xml\"}},\"name\":\"source.java.embedded.xml\",\"patterns\":[{\"include\":\"source.java\"}]},{\"begin\":\"<!\\\\[CDATA\\\\[\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.begin.xml\"}},\"end\":\"]]>\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.end.xml\"}},\"name\":\"string.unquoted.cdata.xml\"}],\"repository\":{\"EntityDecl\":{\"begin\":\"(<!)(ENTITY)\\\\s+(%\\\\s+)?([:A-Z_a-z][-.0-:A-Z_a-z]*)(\\\\s+(?:SYSTEM|PUBLIC)\\\\s+)?\",\"captures\":{\"1\":{\"name\":\"punctuation.definition.tag.xml\"},\"2\":{\"name\":\"keyword.other.entity.xml\"},\"3\":{\"name\":\"punctuation.definition.entity.xml\"},\"4\":{\"name\":\"variable.language.entity.xml\"},\"5\":{\"name\":\"keyword.other.entitytype.xml\"}},\"end\":\"(>)\",\"patterns\":[{\"include\":\"#doublequotedString\"},{\"include\":\"#singlequotedString\"}]},\"bare-ampersand\":{\"match\":\"&\",\"name\":\"invalid.illegal.bad-ampersand.xml\"},\"comments\":{\"patterns\":[{\"begin\":\"<%--\",\"captures\":{\"0\":{\"name\":\"punctuation.definition.comment.xml\"},\"end\":\"--%>\",\"name\":\"comment.block.xml\"}},{\"begin\":\"<!--\",\"captures\":{\"0\":{\"name\":\"punctuation.definition.comment.xml\"}},\"end\":\"-->\",\"name\":\"comment.block.xml\",\"patterns\":[{\"begin\":\"--(?!>)\",\"captures\":{\"0\":{\"name\":\"invalid.illegal.bad-comments-or-CDATA.xml\"}}}]}]},\"doublequotedString\":{\"begin\":\"\\\"\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.begin.xml\"}},\"end\":\"\\\"\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.end.xml\"}},\"name\":\"string.quoted.double.xml\",\"patterns\":[{\"include\":\"#entity\"},{\"include\":\"#bare-ampersand\"}]},\"entity\":{\"captures\":{\"1\":{\"name\":\"punctuation.definition.constant.xml\"},\"3\":{\"name\":\"punctuation.definition.constant.xml\"}},\"match\":\"(&)([:A-Z_a-z][-.0-:A-Z_a-z]*|#[0-9]+|#x\\\\h+)(;)\",\"name\":\"constant.character.entity.xml\"},\"internalSubset\":{\"begin\":\"(\\\\[)\",\"captures\":{\"1\":{\"name\":\"punctuation.definition.constant.xml\"}},\"end\":\"(])\",\"name\":\"meta.internalsubset.xml\",\"patterns\":[{\"include\":\"#EntityDecl\"},{\"include\":\"#parameterEntity\"},{\"include\":\"#comments\"}]},\"parameterEntity\":{\"captures\":{\"1\":{\"name\":\"punctuation.definition.constant.xml\"},\"3\":{\"name\":\"punctuation.definition.constant.xml\"}},\"match\":\"(%)([:A-Z_a-z][-.0-:A-Z_a-z]*)(;)\",\"name\":\"constant.character.parameter-entity.xml\"},\"singlequotedString\":{\"begin\":\"'\",\"beginCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.begin.xml\"}},\"end\":\"'\",\"endCaptures\":{\"0\":{\"name\":\"punctuation.definition.string.end.xml\"}},\"name\":\"string.quoted.single.xml\",\"patterns\":[{\"include\":\"#entity\"},{\"include\":\"#bare-ampersand\"}]},\"tagStuff\":{\"patterns\":[{\"captures\":{\"1\":{\"name\":\"entity.other.attribute-name.namespace.xml\"},\"2\":{\"name\":\"entity.other.attribute-name.xml\"},\"3\":{\"name\":\"punctuation.separator.namespace.xml\"},\"4\":{\"name\":\"entity.other.attribute-name.localname.xml\"}},\"match\":\"(?:^|\\\\s+)(?:([-.\\\\w]+)((:)))?([-.:\\\\w]+)\\\\s*=\"},{\"include\":\"#doublequotedString\"},{\"include\":\"#singlequotedString\"}]}},\"scopeName\":\"text.xml\",\"embeddedLangs\":[\"java\"]}"));
|
package/client/dist/index.html
CHANGED
|
@@ -5,9 +5,9 @@
|
|
|
5
5
|
<link rel="icon" type="image/svg+xml" href="/vite.svg" />
|
|
6
6
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
7
7
|
<title>Intlayer Editor</title>
|
|
8
|
-
<script type="module" crossorigin src="/assets/index-
|
|
9
|
-
<link rel="modulepreload" crossorigin href="/assets/chunk-
|
|
10
|
-
<link rel="modulepreload" crossorigin href="/assets/react-
|
|
8
|
+
<script type="module" crossorigin src="/assets/index-1h009QuF.js"></script>
|
|
9
|
+
<link rel="modulepreload" crossorigin href="/assets/chunk-C0u3WHrm.js">
|
|
10
|
+
<link rel="modulepreload" crossorigin href="/assets/react-BI_C_976.js">
|
|
11
11
|
<link rel="stylesheet" crossorigin href="/assets/index-D6NEtBOG.css">
|
|
12
12
|
</head>
|
|
13
13
|
<body>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "intlayer-editor",
|
|
3
|
-
"version": "8.4.
|
|
3
|
+
"version": "8.4.4",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Integrate the Intlayer visual editor into your Intlayer projects, enabling CMS-like content management with multilingual support.",
|
|
6
6
|
"keywords": [
|
|
@@ -93,17 +93,17 @@
|
|
|
93
93
|
"@fastify/formbody": "8.0.2",
|
|
94
94
|
"@fastify/helmet": "13.0.2",
|
|
95
95
|
"@fastify/static": "9.0.0",
|
|
96
|
-
"@intlayer/chokidar": "8.4.
|
|
97
|
-
"@intlayer/config": "8.4.
|
|
98
|
-
"@intlayer/unmerged-dictionaries-entry": "8.4.
|
|
96
|
+
"@intlayer/chokidar": "8.4.4",
|
|
97
|
+
"@intlayer/config": "8.4.4",
|
|
98
|
+
"@intlayer/unmerged-dictionaries-entry": "8.4.4",
|
|
99
99
|
"fastify": "5.8.2",
|
|
100
|
-
"fastify-intlayer": "8.4.
|
|
100
|
+
"fastify-intlayer": "8.4.4",
|
|
101
101
|
"mime": "4.1.0"
|
|
102
102
|
},
|
|
103
103
|
"devDependencies": {
|
|
104
|
-
"@intlayer/design-system": "8.4.
|
|
105
|
-
"@intlayer/editor-react": "8.4.
|
|
106
|
-
"@intlayer/types": "8.4.
|
|
104
|
+
"@intlayer/design-system": "8.4.4",
|
|
105
|
+
"@intlayer/editor-react": "8.4.4",
|
|
106
|
+
"@intlayer/types": "8.4.4",
|
|
107
107
|
"@tailwindcss/vite": "4.2.1",
|
|
108
108
|
"@tanstack/react-query": "5.91.0",
|
|
109
109
|
"@types/node": "25.5.0",
|
|
@@ -117,18 +117,18 @@
|
|
|
117
117
|
"framer-motion": "12.38.0",
|
|
118
118
|
"fuse.js": "7.1.0",
|
|
119
119
|
"globals": "17.4.0",
|
|
120
|
-
"intlayer": "8.4.
|
|
120
|
+
"intlayer": "8.4.4",
|
|
121
121
|
"lucide-react": "0.577.0",
|
|
122
122
|
"react": "19.2.4",
|
|
123
123
|
"react-dom": "19.2.4",
|
|
124
|
-
"react-intlayer": "8.4.
|
|
124
|
+
"react-intlayer": "8.4.4",
|
|
125
125
|
"react-router-dom": "7.13.1",
|
|
126
126
|
"tailwind-merge": "3.5.0",
|
|
127
127
|
"tailwindcss": "4.2.2",
|
|
128
128
|
"tsdown": "0.21.4",
|
|
129
129
|
"typescript": "5.9.3",
|
|
130
130
|
"vite": "8.0.0",
|
|
131
|
-
"vite-intlayer": "8.4.
|
|
131
|
+
"vite-intlayer": "8.4.4",
|
|
132
132
|
"vitest": "4.1.0"
|
|
133
133
|
},
|
|
134
134
|
"engines": {
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
//#region \0rolldown/runtime.js
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __copyProps = (to, from, except, desc) => {
|
|
9
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
10
|
+
for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
11
|
+
key = keys[i];
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except) {
|
|
13
|
+
__defProp(to, key, {
|
|
14
|
+
get: ((k) => from[k]).bind(null, key),
|
|
15
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
return to;
|
|
21
|
+
};
|
|
22
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
23
|
+
value: mod,
|
|
24
|
+
enumerable: true
|
|
25
|
+
}) : target, mod));
|
|
26
|
+
|
|
27
|
+
//#endregion
|
|
28
|
+
let node_net = require("node:net");
|
|
29
|
+
node_net = __toESM(node_net);
|
|
30
|
+
|
|
31
|
+
//#region src/utils/checkPortAvailability.ts
|
|
32
|
+
const checkPortAvailability = (port) => {
|
|
33
|
+
return new Promise((resolve) => {
|
|
34
|
+
const server = node_net.default.createServer();
|
|
35
|
+
server.once("error", (err) => {
|
|
36
|
+
if (err.code === "EADDRINUSE") resolve(false);
|
|
37
|
+
else resolve(true);
|
|
38
|
+
});
|
|
39
|
+
server.once("listening", () => {
|
|
40
|
+
server.close();
|
|
41
|
+
resolve(true);
|
|
42
|
+
});
|
|
43
|
+
server.listen(port);
|
|
44
|
+
});
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
//#endregion
|
|
48
|
+
Object.defineProperty(exports, '__toESM', {
|
|
49
|
+
enumerable: true,
|
|
50
|
+
get: function () {
|
|
51
|
+
return __toESM;
|
|
52
|
+
}
|
|
53
|
+
});
|
|
54
|
+
Object.defineProperty(exports, 'checkPortAvailability', {
|
|
55
|
+
enumerable: true,
|
|
56
|
+
get: function () {
|
|
57
|
+
return checkPortAvailability;
|
|
58
|
+
}
|
|
59
|
+
});
|
|
60
|
+
//# sourceMappingURL=checkPortAvailability-BJtgxTDw.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"checkPortAvailability-BJtgxTDw.cjs","names":["net"],"sources":["../src/utils/checkPortAvailability.ts"],"sourcesContent":["import net from 'node:net';\n\nexport const checkPortAvailability = (port: number): Promise<boolean> => {\n return new Promise((resolve) => {\n const server = net.createServer();\n\n server.once('error', (err: any) => {\n if (err.code === 'EADDRINUSE') {\n resolve(false); // Port is in use\n } else {\n resolve(true);\n }\n });\n\n server.once('listening', () => {\n server.close();\n resolve(true); // Port is available\n });\n\n server.listen(port);\n });\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,MAAa,yBAAyB,SAAmC;AACvE,QAAO,IAAI,SAAS,YAAY;EAC9B,MAAM,SAASA,iBAAI,cAAc;AAEjC,SAAO,KAAK,UAAU,QAAa;AACjC,OAAI,IAAI,SAAS,aACf,SAAQ,MAAM;OAEd,SAAQ,KAAK;IAEf;AAEF,SAAO,KAAK,mBAAmB;AAC7B,UAAO,OAAO;AACd,WAAQ,KAAK;IACb;AAEF,SAAO,OAAO,KAAK;GACnB"}
|
package/server/dist/index.cjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
const e=require(`./checkPortAvailability-BQTphbYJ.cjs`),t=require(`./routes/config.routes.cjs`),n=require(`./routes/dictionary.routes.cjs`);let r=require(`@intlayer/config/node`),i=require(`fastify-intlayer`),a=require(`node:fs`),o=require(`node:path`),s=require(`node:url`),c=require(`@fastify/compress`);c=e.n(c);let l=require(`@fastify/cookie`);l=e.n(l);let u=require(`@fastify/cors`);u=e.n(u);let d=require(`@fastify/formbody`);d=e.n(d);let f=require(`@fastify/helmet`);f=e.n(f);let p=require(`@fastify/static`);p=e.n(p);let m=require(`@intlayer/config/env`),
|
|
2
|
-
${(0,
|
|
1
|
+
const e=require(`./checkPortAvailability-BQTphbYJ.cjs`),t=require(`./routes/config.routes.cjs`),n=require(`./routes/dictionary.routes.cjs`);let r=require(`@intlayer/config/node`),i=require(`fastify-intlayer`),a=require(`node:fs`),o=require(`node:path`),s=require(`node:url`),c=require(`@fastify/compress`);c=e.n(c);let l=require(`@fastify/cookie`);l=e.n(l);let u=require(`@fastify/cors`);u=e.n(u);let d=require(`@fastify/formbody`);d=e.n(d);let f=require(`@fastify/helmet`);f=e.n(f);let p=require(`@fastify/static`);p=e.n(p);let m=require(`@intlayer/config/colors`);m=e.n(m);let h=require(`@intlayer/config/env`),g=require(`@intlayer/config/logger`),_=require(`fastify`);_=e.n(_);let v=require(`mime`);v=e.n(v);const y=(0,o.dirname)((0,s.fileURLToPath)(require(`url`).pathToFileURL(__filename).href)),b={env:process.env.NODE_ENV,envFile:process.env.ENV_FILE},x=(0,r.getConfiguration)(b),S=(0,g.getAppLogger)(x),C=x.editor.port??8e3;x.editor.enabled||(S(`Editor is not enabled. Add ${(0,g.colorize)(`editor.enabled`,m.BLUE)} to ${(0,g.colorizePath)(`intlayer.config.ts`)} file to enable it.`,{level:`error`}),process.exit(0));const w=JSON.parse((0,a.readFileSync)((0,o.resolve)(y,`../../package.json`),`utf8`)),T=(0,_.default)({disableRequestLogging:!0});T.register(i.intlayer);const E=(0,o.resolve)(y,`../../client/dist`),D={origin:`*`,credentials:!0};(async r=>{await e.t(C)||(S(`Error: Port ${C} is already in use.`,{level:`error`}),process.exit(255)),await r.register(f.default,{contentSecurityPolicy:!1,global:!0}),await r.register(u.default,D),await r.register(c.default),await r.register(l.default),await r.register(d.default),await r.register(n.dictionaryRouter,{prefix:`/api/dictionary`}),await r.register(t.configurationRouter,{prefix:`/api/config`}),await r.register(p.default,{root:E,wildcard:!1}),r.setNotFoundHandler((e,t)=>{let n=(0,o.join)(E,e.raw.url||`/`);if((0,a.existsSync)(n)&&(0,a.lstatSync)(n).isFile()){let r=v.default.getType(n)??`application/octet-stream`;return t.header(`Content-Type`,r),t.sendFile(e.raw.url?.split(`/`).pop()||`index.html`)}else return t.sendFile(`index.html`)});try{await r.listen({port:C,host:`0.0.0.0`});let e=(0,h.getEnvFilePath)(b.env,b.envFile);console.log(`
|
|
2
|
+
${(0,g.colorize)((0,g.colorize)(`INTLAYER`,m.BOLD),m.GREY_DARK)} ${(0,g.colorize)(`v${w.version}`,m.GREY_DARK)}
|
|
3
3
|
|
|
4
|
-
Editor running at: ${(0,
|
|
5
|
-
${(0,
|
|
6
|
-
${(0,
|
|
7
|
-
${(0,
|
|
8
|
-
`)}catch(e){r.log.error(e),process.exit(1)}})(
|
|
4
|
+
Editor running at: ${(0,g.colorizePath)(`http://localhost:${C}`)}
|
|
5
|
+
${(0,g.colorize)(`➜`,m.GREY_DARK)} Watching application at: ${x.editor.applicationURL===``?`-`:(0,g.colorizePath)(x.editor.applicationURL)}
|
|
6
|
+
${(0,g.colorize)(`➜`,m.GREY_DARK)} Access key: ${x.editor.clientId??`-`}
|
|
7
|
+
${(0,g.colorize)(`➜`,m.GREY_DARK)} Environment: ${e??`-`}
|
|
8
|
+
`)}catch(e){r.log.error(e),process.exit(1)}})(T);
|
|
9
9
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","names":["__dirname","ANSIColors","intlayer","checkPortAvailability","fastifyHelmet","fastifyCors","fastifyCompress","fastifyCookie","fastifyFormbody","dictionaryRouter","configurationRouter","fastifyStatic"],"sources":["../src/index.ts"],"sourcesContent":["import { existsSync, lstatSync, readFileSync } from 'node:fs';\nimport { dirname, join, resolve } from 'node:path';\nimport { fileURLToPath } from 'node:url';\nimport fastifyCompress from '@fastify/compress';\nimport fastifyCookie from '@fastify/cookie';\nimport fastifyCors, { type FastifyCorsOptions } from '@fastify/cors';\nimport fastifyFormbody from '@fastify/formbody';\nimport fastifyHelmet from '@fastify/helmet';\nimport fastifyStatic from '@fastify/static';\nimport { getEnvFilePath } from '@intlayer/config/env';\nimport {
|
|
1
|
+
{"version":3,"file":"index.cjs","names":["__dirname","ANSIColors","intlayer","checkPortAvailability","fastifyHelmet","fastifyCors","fastifyCompress","fastifyCookie","fastifyFormbody","dictionaryRouter","configurationRouter","fastifyStatic"],"sources":["../src/index.ts"],"sourcesContent":["import { existsSync, lstatSync, readFileSync } from 'node:fs';\nimport { dirname, join, resolve } from 'node:path';\nimport { fileURLToPath } from 'node:url';\nimport fastifyCompress from '@fastify/compress';\nimport fastifyCookie from '@fastify/cookie';\nimport fastifyCors, { type FastifyCorsOptions } from '@fastify/cors';\nimport fastifyFormbody from '@fastify/formbody';\nimport fastifyHelmet from '@fastify/helmet';\nimport fastifyStatic from '@fastify/static';\nimport * as ANSIColors from '@intlayer/config/colors';\nimport { getEnvFilePath } from '@intlayer/config/env';\nimport { colorize, colorizePath, getAppLogger } from '@intlayer/config/logger';\nimport { getConfiguration } from '@intlayer/config/node';\nimport { configurationRouter } from '@routes/config.routes';\nimport { dictionaryRouter } from '@routes/dictionary.routes';\nimport { checkPortAvailability } from '@utils/checkPortAvailability';\nimport Fastify, { type FastifyInstance } from 'fastify';\nimport { intlayer } from 'fastify-intlayer';\nimport mime from 'mime';\n\nconst __dirname = dirname(fileURLToPath(import.meta.url));\n\nconst envFileOptions = {\n env: process.env.NODE_ENV,\n envFile: process.env.ENV_FILE,\n};\n\nconst FALLBACK_PORT = 8000;\nconst config = getConfiguration(envFileOptions);\n\nconst appLogger = getAppLogger(config);\nconst port = config.editor.port ?? FALLBACK_PORT;\n\nif (!config.editor.enabled) {\n appLogger(\n `Editor is not enabled. Add ${colorize('editor.enabled', ANSIColors.BLUE)} to ${colorizePath('intlayer.config.ts')} file to enable it.`,\n {\n level: 'error',\n }\n );\n process.exit(0);\n}\n\n// Load package.json\nconst packageJson = JSON.parse(\n readFileSync(resolve(__dirname, '../../package.json'), 'utf8')\n);\n\nconst app: FastifyInstance = Fastify({\n disableRequestLogging: true, // Optional: Keep logs clean like the original\n});\n\n// Load internationalization plugin\n// Assuming fastify-intlayer is the Fastify equivalent of express-intlayer\napp.register(intlayer);\n\nconst clientDistPath = resolve(__dirname, '../../client/dist');\n\nconst corsOptions: FastifyCorsOptions = {\n origin: '*',\n credentials: true,\n};\n\nconst startServer = async (app: FastifyInstance) => {\n const isPortAvailable = await checkPortAvailability(port);\n\n if (!isPortAvailable) {\n appLogger(`Error: Port ${port} is already in use.`, {\n level: 'error',\n });\n process.exit(255);\n }\n\n // Security Headers\n await app.register(fastifyHelmet, {\n contentSecurityPolicy: false,\n global: true,\n });\n\n // CORS\n await app.register(fastifyCors, corsOptions);\n\n // Compression\n await app.register(fastifyCompress);\n\n // Cookie Parser\n await app.register(fastifyCookie);\n\n // Parse application/x-www-form-urlencoded\n await app.register(fastifyFormbody);\n\n // Register Routes\n await app.register(dictionaryRouter, { prefix: '/api/dictionary' });\n await app.register(configurationRouter, { prefix: '/api/config' });\n\n // Serve Static Files\n await app.register(fastifyStatic, {\n root: clientDistPath,\n wildcard: false, // We handle the fallback manually to match SPA logic\n });\n\n // For single-page applications, redirect all unmatched routes to index.html\n app.setNotFoundHandler((req, reply) => {\n const requestedPath = join(clientDistPath, req.raw.url || '/');\n\n if (existsSync(requestedPath) && lstatSync(requestedPath).isFile()) {\n const mimeType =\n mime.getType(requestedPath) ?? 'application/octet-stream';\n reply.header('Content-Type', mimeType);\n return reply.sendFile(req.raw.url?.split('/').pop() || 'index.html');\n } else {\n return reply.sendFile('index.html');\n }\n });\n\n try {\n await app.listen({ port, host: '0.0.0.0' });\n\n const dotEnvFilePath = getEnvFilePath(\n envFileOptions.env,\n envFileOptions.envFile\n );\n\n console.log(`\n ${colorize(colorize('INTLAYER', ANSIColors.BOLD), ANSIColors.GREY_DARK)} ${colorize(`v${packageJson.version}`, ANSIColors.GREY_DARK)}\n\n Editor running at: ${colorizePath(`http://localhost:${port}`)}\n ${colorize('➜', ANSIColors.GREY_DARK)} Watching application at: ${config.editor.applicationURL === '' ? '-' : colorizePath(config.editor.applicationURL)}\n ${colorize('➜', ANSIColors.GREY_DARK)} Access key: ${config.editor.clientId ?? '-'}\n ${colorize('➜', ANSIColors.GREY_DARK)} Environment: ${dotEnvFilePath ?? '-'}\n `);\n } catch (err) {\n app.log.error(err);\n process.exit(1);\n }\n};\n\n// Start it up!\nstartServer(app);\n"],"mappings":"usBAoBA,MAAMA,GAAAA,EAAAA,EAAAA,UAAAA,EAAAA,EAAAA,eAAAA,QAAAA,MAAAA,CAAAA,cAAAA,WAAAA,CAAAA,KAAkD,CAAC,CAEnD,EAAiB,CACrB,IAAK,QAAQ,IAAI,SACjB,QAAS,QAAQ,IAAI,SACtB,CAGK,GAAA,EAAA,EAAA,kBAA0B,EAAe,CAEzC,GAAA,EAAA,EAAA,cAAyB,EAAO,CAChC,EAAO,EAAO,OAAO,MAAQ,IAE9B,EAAO,OAAO,UACjB,EACE,+BAAA,EAAA,EAAA,UAAuC,iBAAkBC,EAAW,KAAK,CAAC,OAAA,EAAA,EAAA,cAAmB,qBAAqB,CAAC,qBACnH,CACE,MAAO,QACR,CACF,CACD,QAAQ,KAAK,EAAE,EAIjB,MAAM,EAAc,KAAK,OAAA,EAAA,EAAA,eAAA,EAAA,EAAA,SACFD,EAAW,qBAAqB,CAAE,OAAO,CAC/D,CAEK,GAAA,EAAA,EAAA,SAA+B,CACnC,sBAAuB,GACxB,CAAC,CAIF,EAAI,SAASE,EAAAA,SAAS,CAEtB,MAAM,GAAA,EAAA,EAAA,SAAyBF,EAAW,oBAAoB,CAExD,EAAkC,CACtC,OAAQ,IACR,YAAa,GACd,EAEmB,KAAO,IAAyB,CAC1B,MAAMG,EAAAA,EAAsB,EAAK,GAGvD,EAAU,eAAe,EAAK,qBAAsB,CAClD,MAAO,QACR,CAAC,CACF,QAAQ,KAAK,IAAI,EAInB,MAAM,EAAI,SAASC,EAAAA,QAAe,CAChC,sBAAuB,GACvB,OAAQ,GACT,CAAC,CAGF,MAAM,EAAI,SAASC,EAAAA,QAAa,EAAY,CAG5C,MAAM,EAAI,SAASC,EAAAA,QAAgB,CAGnC,MAAM,EAAI,SAASC,EAAAA,QAAc,CAGjC,MAAM,EAAI,SAASC,EAAAA,QAAgB,CAGnC,MAAM,EAAI,SAASC,EAAAA,iBAAkB,CAAE,OAAQ,kBAAmB,CAAC,CACnE,MAAM,EAAI,SAASC,EAAAA,oBAAqB,CAAE,OAAQ,cAAe,CAAC,CAGlE,MAAM,EAAI,SAASC,EAAAA,QAAe,CAChC,KAAM,EACN,SAAU,GACX,CAAC,CAGF,EAAI,oBAAoB,EAAK,IAAU,CACrC,IAAM,GAAA,EAAA,EAAA,MAAqB,EAAgB,EAAI,IAAI,KAAO,IAAI,CAE9D,IAAA,EAAA,EAAA,YAAe,EAAc,GAAA,EAAA,EAAA,WAAc,EAAc,CAAC,QAAQ,CAAE,CAClE,IAAM,EACJ,EAAA,QAAK,QAAQ,EAAc,EAAI,2BAEjC,OADA,EAAM,OAAO,eAAgB,EAAS,CAC/B,EAAM,SAAS,EAAI,IAAI,KAAK,MAAM,IAAI,CAAC,KAAK,EAAI,aAAa,MAEpE,OAAO,EAAM,SAAS,aAAa,EAErC,CAEF,GAAI,CACF,MAAM,EAAI,OAAO,CAAE,OAAM,KAAM,UAAW,CAAC,CAE3C,IAAM,GAAA,EAAA,EAAA,gBACJ,EAAe,IACf,EAAe,QAChB,CAED,QAAQ,IAAI;oCACQ,WAAYV,EAAW,KAAK,CAAEA,EAAW,UAAU,CAAC,IAAA,EAAA,EAAA,UAAY,IAAI,EAAY,UAAWA,EAAW,UAAU,CAAC;;sDAEzF,oBAAoB,IAAO,CAAC;qBAC7D,IAAKA,EAAW,UAAU,CAAC,8BAA8B,EAAO,OAAO,iBAAmB,GAAK,KAAA,EAAA,EAAA,cAAmB,EAAO,OAAO,eAAe,CAAC;qBAChJ,IAAKA,EAAW,UAAU,CAAC,8BAA8B,EAAO,OAAO,UAAY,IAAI;qBACvF,IAAKA,EAAW,UAAU,CAAC,8BAA8B,GAAkB,IAAI;MACxF,OACK,EAAK,CACZ,EAAI,IAAI,MAAM,EAAI,CAClB,QAAQ,KAAK,EAAE,IAKP,EAAI"}
|
package/server/dist/index.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import{configurationRouter as e}from"./routes/config.routes.mjs";import{dictionaryRouter as t}from"./routes/dictionary.routes.mjs";import{checkPortAvailability as n}from"./utils/checkPortAvailability.mjs";import{getConfiguration as r}from"@intlayer/config/node";import{intlayer as i}from"fastify-intlayer";import{existsSync as a,lstatSync as o,readFileSync as s}from"node:fs";import{dirname as c,join as l,resolve as u}from"node:path";import{fileURLToPath as d}from"node:url";import f from"@fastify/compress";import p from"@fastify/cookie";import m from"@fastify/cors";import h from"@fastify/formbody";import g from"@fastify/helmet";import _ from"@fastify/static";import{getEnvFilePath as
|
|
2
|
-
${b(b(`INTLAYER`,
|
|
1
|
+
import{configurationRouter as e}from"./routes/config.routes.mjs";import{dictionaryRouter as t}from"./routes/dictionary.routes.mjs";import{checkPortAvailability as n}from"./utils/checkPortAvailability.mjs";import{getConfiguration as r}from"@intlayer/config/node";import{intlayer as i}from"fastify-intlayer";import{existsSync as a,lstatSync as o,readFileSync as s}from"node:fs";import{dirname as c,join as l,resolve as u}from"node:path";import{fileURLToPath as d}from"node:url";import f from"@fastify/compress";import p from"@fastify/cookie";import m from"@fastify/cors";import h from"@fastify/formbody";import g from"@fastify/helmet";import _ from"@fastify/static";import*as v from"@intlayer/config/colors";import{getEnvFilePath as y}from"@intlayer/config/env";import{colorize as b,colorizePath as x,getAppLogger as S}from"@intlayer/config/logger";import C from"fastify";import w from"mime";const T=c(d(import.meta.url)),E={env:`production`,envFile:process.env.ENV_FILE},D=r(E),O=S(D),k=D.editor.port??8e3;D.editor.enabled||(O(`Editor is not enabled. Add ${b(`editor.enabled`,v.BLUE)} to ${x(`intlayer.config.ts`)} file to enable it.`,{level:`error`}),process.exit(0));const A=JSON.parse(s(u(T,`../../package.json`),`utf8`)),j=C({disableRequestLogging:!0});j.register(i);const M=u(T,`../../client/dist`),N={origin:`*`,credentials:!0};(async r=>{await n(k)||(O(`Error: Port ${k} is already in use.`,{level:`error`}),process.exit(255)),await r.register(g,{contentSecurityPolicy:!1,global:!0}),await r.register(m,N),await r.register(f),await r.register(p),await r.register(h),await r.register(t,{prefix:`/api/dictionary`}),await r.register(e,{prefix:`/api/config`}),await r.register(_,{root:M,wildcard:!1}),r.setNotFoundHandler((e,t)=>{let n=l(M,e.raw.url||`/`);if(a(n)&&o(n).isFile()){let r=w.getType(n)??`application/octet-stream`;return t.header(`Content-Type`,r),t.sendFile(e.raw.url?.split(`/`).pop()||`index.html`)}else return t.sendFile(`index.html`)});try{await r.listen({port:k,host:`0.0.0.0`});let e=y(E.env,E.envFile);console.log(`
|
|
2
|
+
${b(b(`INTLAYER`,v.BOLD),v.GREY_DARK)} ${b(`v${A.version}`,v.GREY_DARK)}
|
|
3
3
|
|
|
4
4
|
Editor running at: ${x(`http://localhost:${k}`)}
|
|
5
|
-
${b(`➜`,
|
|
6
|
-
${b(`➜`,
|
|
7
|
-
${b(`➜`,
|
|
5
|
+
${b(`➜`,v.GREY_DARK)} Watching application at: ${D.editor.applicationURL===``?`-`:x(D.editor.applicationURL)}
|
|
6
|
+
${b(`➜`,v.GREY_DARK)} Access key: ${D.editor.clientId??`-`}
|
|
7
|
+
${b(`➜`,v.GREY_DARK)} Environment: ${e??`-`}
|
|
8
8
|
`)}catch(e){r.log.error(e),process.exit(1)}})(j);
|
|
9
9
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","names":[],"sources":["../src/index.ts"],"sourcesContent":["import { existsSync, lstatSync, readFileSync } from 'node:fs';\nimport { dirname, join, resolve } from 'node:path';\nimport { fileURLToPath } from 'node:url';\nimport fastifyCompress from '@fastify/compress';\nimport fastifyCookie from '@fastify/cookie';\nimport fastifyCors, { type FastifyCorsOptions } from '@fastify/cors';\nimport fastifyFormbody from '@fastify/formbody';\nimport fastifyHelmet from '@fastify/helmet';\nimport fastifyStatic from '@fastify/static';\nimport { getEnvFilePath } from '@intlayer/config/env';\nimport {
|
|
1
|
+
{"version":3,"file":"index.mjs","names":[],"sources":["../src/index.ts"],"sourcesContent":["import { existsSync, lstatSync, readFileSync } from 'node:fs';\nimport { dirname, join, resolve } from 'node:path';\nimport { fileURLToPath } from 'node:url';\nimport fastifyCompress from '@fastify/compress';\nimport fastifyCookie from '@fastify/cookie';\nimport fastifyCors, { type FastifyCorsOptions } from '@fastify/cors';\nimport fastifyFormbody from '@fastify/formbody';\nimport fastifyHelmet from '@fastify/helmet';\nimport fastifyStatic from '@fastify/static';\nimport * as ANSIColors from '@intlayer/config/colors';\nimport { getEnvFilePath } from '@intlayer/config/env';\nimport { colorize, colorizePath, getAppLogger } from '@intlayer/config/logger';\nimport { getConfiguration } from '@intlayer/config/node';\nimport { configurationRouter } from '@routes/config.routes';\nimport { dictionaryRouter } from '@routes/dictionary.routes';\nimport { checkPortAvailability } from '@utils/checkPortAvailability';\nimport Fastify, { type FastifyInstance } from 'fastify';\nimport { intlayer } from 'fastify-intlayer';\nimport mime from 'mime';\n\nconst __dirname = dirname(fileURLToPath(import.meta.url));\n\nconst envFileOptions = {\n env: process.env.NODE_ENV,\n envFile: process.env.ENV_FILE,\n};\n\nconst FALLBACK_PORT = 8000;\nconst config = getConfiguration(envFileOptions);\n\nconst appLogger = getAppLogger(config);\nconst port = config.editor.port ?? FALLBACK_PORT;\n\nif (!config.editor.enabled) {\n appLogger(\n `Editor is not enabled. Add ${colorize('editor.enabled', ANSIColors.BLUE)} to ${colorizePath('intlayer.config.ts')} file to enable it.`,\n {\n level: 'error',\n }\n );\n process.exit(0);\n}\n\n// Load package.json\nconst packageJson = JSON.parse(\n readFileSync(resolve(__dirname, '../../package.json'), 'utf8')\n);\n\nconst app: FastifyInstance = Fastify({\n disableRequestLogging: true, // Optional: Keep logs clean like the original\n});\n\n// Load internationalization plugin\n// Assuming fastify-intlayer is the Fastify equivalent of express-intlayer\napp.register(intlayer);\n\nconst clientDistPath = resolve(__dirname, '../../client/dist');\n\nconst corsOptions: FastifyCorsOptions = {\n origin: '*',\n credentials: true,\n};\n\nconst startServer = async (app: FastifyInstance) => {\n const isPortAvailable = await checkPortAvailability(port);\n\n if (!isPortAvailable) {\n appLogger(`Error: Port ${port} is already in use.`, {\n level: 'error',\n });\n process.exit(255);\n }\n\n // Security Headers\n await app.register(fastifyHelmet, {\n contentSecurityPolicy: false,\n global: true,\n });\n\n // CORS\n await app.register(fastifyCors, corsOptions);\n\n // Compression\n await app.register(fastifyCompress);\n\n // Cookie Parser\n await app.register(fastifyCookie);\n\n // Parse application/x-www-form-urlencoded\n await app.register(fastifyFormbody);\n\n // Register Routes\n await app.register(dictionaryRouter, { prefix: '/api/dictionary' });\n await app.register(configurationRouter, { prefix: '/api/config' });\n\n // Serve Static Files\n await app.register(fastifyStatic, {\n root: clientDistPath,\n wildcard: false, // We handle the fallback manually to match SPA logic\n });\n\n // For single-page applications, redirect all unmatched routes to index.html\n app.setNotFoundHandler((req, reply) => {\n const requestedPath = join(clientDistPath, req.raw.url || '/');\n\n if (existsSync(requestedPath) && lstatSync(requestedPath).isFile()) {\n const mimeType =\n mime.getType(requestedPath) ?? 'application/octet-stream';\n reply.header('Content-Type', mimeType);\n return reply.sendFile(req.raw.url?.split('/').pop() || 'index.html');\n } else {\n return reply.sendFile('index.html');\n }\n });\n\n try {\n await app.listen({ port, host: '0.0.0.0' });\n\n const dotEnvFilePath = getEnvFilePath(\n envFileOptions.env,\n envFileOptions.envFile\n );\n\n console.log(`\n ${colorize(colorize('INTLAYER', ANSIColors.BOLD), ANSIColors.GREY_DARK)} ${colorize(`v${packageJson.version}`, ANSIColors.GREY_DARK)}\n\n Editor running at: ${colorizePath(`http://localhost:${port}`)}\n ${colorize('➜', ANSIColors.GREY_DARK)} Watching application at: ${config.editor.applicationURL === '' ? '-' : colorizePath(config.editor.applicationURL)}\n ${colorize('➜', ANSIColors.GREY_DARK)} Access key: ${config.editor.clientId ?? '-'}\n ${colorize('➜', ANSIColors.GREY_DARK)} Environment: ${dotEnvFilePath ?? '-'}\n `);\n } catch (err) {\n app.log.error(err);\n process.exit(1);\n }\n};\n\n// Start it up!\nstartServer(app);\n"],"mappings":"03BAoBA,MAAM,EAAY,EAAQ,EAAc,OAAO,KAAK,IAAI,CAAC,CAEnD,EAAiB,CACrB,IAAA,aACA,QAAS,QAAQ,IAAI,SACtB,CAGK,EAAS,EAAiB,EAAe,CAEzC,EAAY,EAAa,EAAO,CAChC,EAAO,EAAO,OAAO,MAAQ,IAE9B,EAAO,OAAO,UACjB,EACE,8BAA8B,EAAS,iBAAkB,EAAW,KAAK,CAAC,MAAM,EAAa,qBAAqB,CAAC,qBACnH,CACE,MAAO,QACR,CACF,CACD,QAAQ,KAAK,EAAE,EAIjB,MAAM,EAAc,KAAK,MACvB,EAAa,EAAQ,EAAW,qBAAqB,CAAE,OAAO,CAC/D,CAEK,EAAuB,EAAQ,CACnC,sBAAuB,GACxB,CAAC,CAIF,EAAI,SAAS,EAAS,CAEtB,MAAM,EAAiB,EAAQ,EAAW,oBAAoB,CAExD,EAAkC,CACtC,OAAQ,IACR,YAAa,GACd,EAEmB,KAAO,IAAyB,CAC1B,MAAM,EAAsB,EAAK,GAGvD,EAAU,eAAe,EAAK,qBAAsB,CAClD,MAAO,QACR,CAAC,CACF,QAAQ,KAAK,IAAI,EAInB,MAAM,EAAI,SAAS,EAAe,CAChC,sBAAuB,GACvB,OAAQ,GACT,CAAC,CAGF,MAAM,EAAI,SAAS,EAAa,EAAY,CAG5C,MAAM,EAAI,SAAS,EAAgB,CAGnC,MAAM,EAAI,SAAS,EAAc,CAGjC,MAAM,EAAI,SAAS,EAAgB,CAGnC,MAAM,EAAI,SAAS,EAAkB,CAAE,OAAQ,kBAAmB,CAAC,CACnE,MAAM,EAAI,SAAS,EAAqB,CAAE,OAAQ,cAAe,CAAC,CAGlE,MAAM,EAAI,SAAS,EAAe,CAChC,KAAM,EACN,SAAU,GACX,CAAC,CAGF,EAAI,oBAAoB,EAAK,IAAU,CACrC,IAAM,EAAgB,EAAK,EAAgB,EAAI,IAAI,KAAO,IAAI,CAE9D,GAAI,EAAW,EAAc,EAAI,EAAU,EAAc,CAAC,QAAQ,CAAE,CAClE,IAAM,EACJ,EAAK,QAAQ,EAAc,EAAI,2BAEjC,OADA,EAAM,OAAO,eAAgB,EAAS,CAC/B,EAAM,SAAS,EAAI,IAAI,KAAK,MAAM,IAAI,CAAC,KAAK,EAAI,aAAa,MAEpE,OAAO,EAAM,SAAS,aAAa,EAErC,CAEF,GAAI,CACF,MAAM,EAAI,OAAO,CAAE,OAAM,KAAM,UAAW,CAAC,CAE3C,IAAM,EAAiB,EACrB,EAAe,IACf,EAAe,QAChB,CAED,QAAQ,IAAI;MACV,EAAS,EAAS,WAAY,EAAW,KAAK,CAAE,EAAW,UAAU,CAAC,GAAG,EAAS,IAAI,EAAY,UAAW,EAAW,UAAU,CAAC;;mCAEtG,EAAa,oBAAoB,IAAO,CAAC;MACtE,EAAS,IAAK,EAAW,UAAU,CAAC,8BAA8B,EAAO,OAAO,iBAAmB,GAAK,IAAM,EAAa,EAAO,OAAO,eAAe,CAAC;MACzJ,EAAS,IAAK,EAAW,UAAU,CAAC,8BAA8B,EAAO,OAAO,UAAY,IAAI;MAChG,EAAS,IAAK,EAAW,UAAU,CAAC,8BAA8B,GAAkB,IAAI;MACxF,OACK,EAAK,CACZ,EAAI,IAAI,MAAM,EAAI,CAClB,QAAQ,KAAK,EAAE,IAKP,EAAI"}
|