@blazetrails/actiontext 0.0.0-stage → 0.1.0-alpha0.2

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 (155) hide show
  1. package/LICENSE +21 -0
  2. package/app/views/action-text/attachables/_content_attachment.html.tse +3 -0
  3. package/app/views/action-text/attachables/_missing_attachable.html.tse +1 -0
  4. package/app/views/action-text/attachables/_remote_image.html.tse +8 -0
  5. package/app/views/action-text/attachment-galleries/_attachment_gallery.html.tse +3 -0
  6. package/app/views/action-text/contents/_content.html.tse +1 -0
  7. package/app/views/active-storage/blobs/_blob.html.tse +14 -0
  8. package/app/views/layouts/action-text/contents/_content.html.tse +3 -0
  9. package/dist/.trails/views/action-text/attachables/_content_attachment.html.tse.js +35 -0
  10. package/dist/.trails/views/action-text/attachables/_content_attachment.html.tse.js.map +1 -0
  11. package/dist/.trails/views/action-text/attachables/_missing_attachable.html.tse.js +16 -0
  12. package/dist/.trails/views/action-text/attachables/_missing_attachable.html.tse.js.map +1 -0
  13. package/dist/.trails/views/action-text/attachables/_remote_image.html.tse.js +42 -0
  14. package/dist/.trails/views/action-text/attachables/_remote_image.html.tse.js.map +1 -0
  15. package/dist/.trails/views/action-text/attachment-galleries/_attachment_gallery.html.tse.js +37 -0
  16. package/dist/.trails/views/action-text/attachment-galleries/_attachment_gallery.html.tse.js.map +1 -0
  17. package/dist/.trails/views/action-text/contents/_content.html.tse.js +34 -0
  18. package/dist/.trails/views/action-text/contents/_content.html.tse.js.map +1 -0
  19. package/dist/.trails/views/active-storage/blobs/_blob.html.tse.js +57 -0
  20. package/dist/.trails/views/active-storage/blobs/_blob.html.tse.js.map +1 -0
  21. package/dist/.trails/views/layouts/action-text/contents/_content.html.tse.js +18 -0
  22. package/dist/.trails/views/layouts/action-text/contents/_content.html.tse.js.map +1 -0
  23. package/dist/action-text.js +73 -0
  24. package/dist/action-text.js.map +1 -0
  25. package/dist/app/helpers/action-text/content-helper.js +84 -0
  26. package/dist/app/helpers/action-text/content-helper.js.map +1 -0
  27. package/dist/app/helpers/action-text/tag-helper.js +115 -0
  28. package/dist/app/helpers/action-text/tag-helper.js.map +1 -0
  29. package/dist/app/views/action-text/attachables/_content_attachment.html.tse +3 -0
  30. package/dist/app/views/action-text/attachables/_missing_attachable.html.tse +1 -0
  31. package/dist/app/views/action-text/attachables/_remote_image.html.tse +8 -0
  32. package/dist/app/views/action-text/attachment-galleries/_attachment_gallery.html.tse +3 -0
  33. package/dist/app/views/action-text/contents/_content.html.tse +1 -0
  34. package/dist/app/views/active-storage/blobs/_blob.html.tse +14 -0
  35. package/dist/app/views/layouts/action-text/contents/_content.html.tse +3 -0
  36. package/dist/attachable.js +118 -0
  37. package/dist/attachable.js.map +1 -0
  38. package/dist/attachables/content-attachment.js +55 -0
  39. package/dist/attachables/content-attachment.js.map +1 -0
  40. package/dist/attachables/missing-attachable.js +30 -0
  41. package/dist/attachables/missing-attachable.js.map +1 -0
  42. package/dist/attachables/remote-image.js +46 -0
  43. package/dist/attachables/remote-image.js.map +1 -0
  44. package/dist/attachment-gallery.js +64 -0
  45. package/dist/attachment-gallery.js.map +1 -0
  46. package/dist/attachment.js +122 -0
  47. package/dist/attachment.js.map +1 -0
  48. package/dist/attachments/caching.js +17 -0
  49. package/dist/attachments/caching.js.map +1 -0
  50. package/dist/attachments/minification.js +15 -0
  51. package/dist/attachments/minification.js.map +1 -0
  52. package/dist/attachments/trix-conversion.js +37 -0
  53. package/dist/attachments/trix-conversion.js.map +1 -0
  54. package/dist/attribute.js +83 -0
  55. package/dist/attribute.js.map +1 -0
  56. package/dist/constants.action-text-install-install-generator.generated.js +4 -0
  57. package/dist/constants.action-text-install-install-generator.generated.js.map +1 -0
  58. package/dist/constants.encrypted-rich-text.generated.js +4 -0
  59. package/dist/constants.encrypted-rich-text.generated.js.map +1 -0
  60. package/dist/constants.engine.generated.js +4 -0
  61. package/dist/constants.engine.generated.js.map +1 -0
  62. package/dist/constants.generated.js +53 -0
  63. package/dist/constants.generated.js.map +1 -0
  64. package/dist/constants.rich-text.generated.js +4 -0
  65. package/dist/constants.rich-text.generated.js.map +1 -0
  66. package/dist/content.js +162 -0
  67. package/dist/content.js.map +1 -0
  68. package/dist/db/migrate/20180528164100_create_action_text_tables.js +31 -0
  69. package/dist/db/migrate/20180528164100_create_action_text_tables.js.map +1 -0
  70. package/dist/deprecator.js +8 -0
  71. package/dist/deprecator.js.map +1 -0
  72. package/dist/encrypted-rich-text.js +12 -0
  73. package/dist/encrypted-rich-text.js.map +1 -0
  74. package/dist/encryption.js +56 -0
  75. package/dist/encryption.js.map +1 -0
  76. package/dist/engine.js +125 -0
  77. package/dist/engine.js.map +1 -0
  78. package/dist/fixture-set.js +14 -0
  79. package/dist/fixture-set.js.map +1 -0
  80. package/dist/fragment.js +59 -0
  81. package/dist/fragment.js.map +1 -0
  82. package/dist/gem-version.js +18 -0
  83. package/dist/gem-version.js.map +1 -0
  84. package/dist/generators/action-text/install/install-generator.js +88 -0
  85. package/dist/generators/action-text/install/install-generator.js.map +1 -0
  86. package/dist/generators/action-text/install/templates/actiontext.css.tt +440 -0
  87. package/dist/generators/action-text/install/templates/actiontext.css.tt.js +12 -0
  88. package/dist/html-conversion.js +21 -0
  89. package/dist/html-conversion.js.map +1 -0
  90. package/dist/index.js +22 -0
  91. package/dist/index.js.map +1 -0
  92. package/dist/plain-text-conversion.js +126 -0
  93. package/dist/plain-text-conversion.js.map +1 -0
  94. package/dist/record.js +11 -0
  95. package/dist/record.js.map +1 -0
  96. package/dist/rendering.js +35 -0
  97. package/dist/rendering.js.map +1 -0
  98. package/dist/rich-text.js +70 -0
  99. package/dist/rich-text.js.map +1 -0
  100. package/dist/serialization.js +30 -0
  101. package/dist/serialization.js.map +1 -0
  102. package/dist/system-test-helper.js +38 -0
  103. package/dist/system-test-helper.js.map +1 -0
  104. package/dist/tasks/actiontext.rake.js +8 -0
  105. package/dist/tasks/actiontext.rake.js.map +1 -0
  106. package/dist/trails/generators/test-unit/install/install-generator.js +16 -0
  107. package/dist/trails/generators/test-unit/install/install-generator.js.map +1 -0
  108. package/dist/trails/generators/test-unit/install/templates/fixtures.yml.tt +4 -0
  109. package/dist/trails/generators/test-unit/install/templates/fixtures.yml.tt.js +12 -0
  110. package/dist/trix-attachment.js +105 -0
  111. package/dist/trix-attachment.js.map +1 -0
  112. package/dist/types/action-text.d.ts +75 -0
  113. package/dist/types/app/helpers/action-text/content-helper.d.ts +35 -0
  114. package/dist/types/app/helpers/action-text/tag-helper.d.ts +48 -0
  115. package/dist/types/attachable.d.ts +41 -0
  116. package/dist/types/attachables/content-attachment.d.ts +30 -0
  117. package/dist/types/attachables/missing-attachable.d.ts +9 -0
  118. package/dist/types/attachables/remote-image.d.ts +23 -0
  119. package/dist/types/attachment-gallery.d.ts +23 -0
  120. package/dist/types/attachment.d.ts +51 -0
  121. package/dist/types/attachments/caching.d.ts +15 -0
  122. package/dist/types/attachments/minification.d.ts +5 -0
  123. package/dist/types/attachments/trix-conversion.d.ts +17 -0
  124. package/dist/types/attribute.d.ts +27 -0
  125. package/dist/types/constants.action-text-install-install-generator.generated.d.ts +2 -0
  126. package/dist/types/constants.encrypted-rich-text.generated.d.ts +2 -0
  127. package/dist/types/constants.engine.generated.d.ts +2 -0
  128. package/dist/types/constants.generated.d.ts +2 -0
  129. package/dist/types/constants.rich-text.generated.d.ts +2 -0
  130. package/dist/types/content.d.ts +73 -0
  131. package/dist/types/db/migrate/20180528164100_create_action_text_tables.d.ts +9 -0
  132. package/dist/types/deprecator.d.ts +3 -0
  133. package/dist/types/encrypted-rich-text.d.ts +5 -0
  134. package/dist/types/encryption.d.ts +30 -0
  135. package/dist/types/engine.d.ts +28 -0
  136. package/dist/types/fixture-set.d.ts +6 -0
  137. package/dist/types/fragment.d.ts +19 -0
  138. package/dist/types/gem-version.d.ts +10 -0
  139. package/dist/types/generators/action-text/install/install-generator.d.ts +25 -0
  140. package/dist/types/html-conversion.d.ts +9 -0
  141. package/dist/types/index.d.ts +22 -0
  142. package/dist/types/plain-text-conversion.d.ts +41 -0
  143. package/dist/types/record.d.ts +4 -0
  144. package/dist/types/rendering.d.ts +15 -0
  145. package/dist/types/rich-text.d.ts +24 -0
  146. package/dist/types/serialization.d.ts +25 -0
  147. package/dist/types/system-test-helper.d.ts +18 -0
  148. package/dist/types/tasks/actiontext.rake.d.ts +2 -0
  149. package/dist/types/trails/generators/test-unit/install/install-generator.d.ts +5 -0
  150. package/dist/types/trix-attachment.d.ts +33 -0
  151. package/dist/types/version.d.ts +3 -0
  152. package/dist/version.js +7 -0
  153. package/dist/version.js.map +1 -0
  154. package/package.json +71 -3
  155. package/README.md +0 -3
package/dist/engine.js ADDED
@@ -0,0 +1,125 @@
1
+ import "./constants.engine.generated.js";
2
+ import { OrderedOptions, TopLevel, onLoad } from "@blazetrails/activesupport";
3
+ import "@blazetrails/trailties/trailties/action-controller";
4
+ import "@blazetrails/trailties/trailties/active-record";
5
+ import { Engine as TrailsEngine } from "@blazetrails/trailties/engine";
6
+ import "@blazetrails/activestorage/engine";
7
+ import { File, include, prepend, rbFRequire, rbClearMethodCache } from "@blazetrails/ruby-compat";
8
+ import { ActionText } from "./action-text.js";
9
+ import { Attachable } from "./attachable.js";
10
+ import { Attachment } from "./attachment.js";
11
+ import { Attribute } from "./attribute.js";
12
+ import { Content } from "./content.js";
13
+ import { ContentHelper } from "./app/helpers/action-text/content-helper.js";
14
+ import { Encryption } from "./encryption.js";
15
+ import "./app/helpers/action-text/tag-helper.js";
16
+ import "./deprecator.js";
17
+ export class Engine extends TrailsEngine {
18
+ static {
19
+ TrailsEngine.register(this, import.meta.dirname);
20
+ this.isolateNamespace(ActionText);
21
+ this.config.eagerLoadNamespaces.push(ActionText);
22
+ this.config.paths().add("db/migrate", {
23
+ with: File.join(import.meta.dirname, "db", "migrate"),
24
+ });
25
+ this.config.paths().add("lib/tasks", {
26
+ with: File.join(import.meta.dirname, "tasks"),
27
+ glob: `*${File.extname(import.meta.filename)}`,
28
+ });
29
+ /** @inventedArm add — PERMANENT */
30
+ this.config.paths().add("app/helpers", {
31
+ with: File.join(import.meta.dirname, "app", "helpers"),
32
+ eagerLoad: true,
33
+ });
34
+ this.config.set("actionText", new OrderedOptions());
35
+ this.config.actionText.attachmentTagName = "action-text-attachment";
36
+ this.config.autoloadOncePaths = [
37
+ File.join(import.meta.dirname, "app", "helpers"),
38
+ File.join(import.meta.dirname, "app", "models"),
39
+ ];
40
+ this.initializer("action_text.deprecator", { before: "load_environment_config" }, (app) => {
41
+ app.deprecators.set("actionText", ActionText.deprecator());
42
+ });
43
+ this.initializer("action_text.attribute", () => {
44
+ onLoad("active_record", function () {
45
+ include(this, Attribute);
46
+ prepend(this, Encryption);
47
+ });
48
+ });
49
+ this.initializer("action_text.asset", () => {
50
+ const config = TopLevel.Trails.application.config;
51
+ if (config.isRespondTo("assets")) {
52
+ const assets = config.get("assets");
53
+ assets.precompile = [
54
+ ...assets.precompile,
55
+ "actiontext.js",
56
+ "actiontext.esm.js",
57
+ "trix.js",
58
+ "trix.css",
59
+ ];
60
+ }
61
+ });
62
+ this.initializer("action_text.attachable", () => {
63
+ onLoad("active_storage_blob", function () {
64
+ include(this, Attachable);
65
+ Object.defineProperty(this.prototype, "isPreviewableAttachable", {
66
+ value: function () {
67
+ return this.isRepresentable();
68
+ },
69
+ writable: true,
70
+ configurable: true,
71
+ });
72
+ rbClearMethodCache();
73
+ Object.defineProperty(this.prototype, "attachablePlainTextRepresentation", {
74
+ value: function (caption = null) {
75
+ return `[${String(caption ?? this.filename)}]`;
76
+ },
77
+ writable: true,
78
+ configurable: true,
79
+ });
80
+ rbClearMethodCache();
81
+ Object.defineProperty(this.prototype, "toTrixContentAttachmentPartialPath", {
82
+ value: function () {
83
+ return null;
84
+ },
85
+ writable: true,
86
+ configurable: true,
87
+ });
88
+ rbClearMethodCache();
89
+ });
90
+ });
91
+ /** @inventedArm await — PERMANENT */
92
+ this.initializer("action_text.helper", async () => {
93
+ const helpers = await Engine.instance().helpers();
94
+ for (const base of ["action_controller_base", "action_mailer"]) {
95
+ onLoad(base, function () {
96
+ this.helper(helpers);
97
+ });
98
+ }
99
+ });
100
+ this.initializer("action_text.renderer", () => {
101
+ for (const base of ["action_controller_base", "action_mailer"]) {
102
+ onLoad(base, function () {
103
+ this.aroundAction((controller, action) => Content.withRenderer(controller, action));
104
+ });
105
+ }
106
+ });
107
+ this.initializer("action_text.system_test_helper", async () => {
108
+ await rbFRequire(ActionText.loadPath, "action_text/system_test_helper");
109
+ onLoad("action_dispatch_system_test_case", function () {
110
+ include(this, ActionText.SystemTestHelper);
111
+ });
112
+ });
113
+ this.initializer("action_text.configure", (app) => {
114
+ Attachment.tagName = app.config.actionText.attachmentTagName;
115
+ });
116
+ this.config.afterInitialize((app) => {
117
+ const klass = app.config.actionText.sanitizerVendor;
118
+ if (klass != null) {
119
+ ContentHelper.sanitizer = new klass.safeListSanitizer();
120
+ }
121
+ });
122
+ }
123
+ }
124
+ ActionText.Engine = Engine;
125
+ //# sourceMappingURL=engine.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"engine.js","sourceRoot":"","sources":["../lib/engine.ts"],"names":[],"mappings":"AAAA,OAAO,iCAAiC,CAAC;AACzC,OAAO,EAAE,cAAc,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,4BAA4B,CAAC;AAE9E,OAAO,oDAAoD,CAAC;AAC5D,OAAO,gDAAgD,CAAC;AACxD,OAAO,EAAE,MAAM,IAAI,YAAY,EAAE,MAAM,+BAA+B,CAAC;AACvE,OAAO,mCAAmC,CAAC;AAC3C,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAClG,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EAA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
+ import { FixtureSet as ActiveRecordFixtureSet } from "@blazetrails/activerecord/fixtures.js";
2
+ import { ActionText } from "./action-text.js";
3
+ import { Attachable } from "./attachable.js";
4
+ export class FixtureSet {
5
+ static attachment(fixtureSetName, label, { columnType = ":integer" } = {}) {
6
+ const signedGlobalId = ActiveRecordFixtureSet.signedGlobalId(fixtureSetName, label, {
7
+ columnType: columnType,
8
+ for: Attachable.LOCATOR_NAME,
9
+ });
10
+ return `<action-text-attachment sgid="${signedGlobalId}"></action-text-attachment>`;
11
+ }
12
+ }
13
+ ActionText.FixtureSet = FixtureSet;
14
+ //# sourceMappingURL=fixture-set.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fixture-set.js","sourceRoot":"","sources":["../lib/fixture-set.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,sBAAsB,EAAE,MAAM,uCAAuC,CAAC;AAE7F,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAE7C,MAAM,OAAO,UAAU;IACrB,MAAM,CAAC,UAAU,CACf,cAAsB,EACtB,KAAa,EACb,EAAE,UAAU,GAAG,UAAU,EAAE,GAA4B,EAAE;QAEzD,MAAM,cAAc,GAClB,sBACD,CAAC,cAAc,CAAC,cAAc,EAAE,KAAK,EAAE;YACtC,UAAU,EAAE,UAAU;YACtB,GAAG,EAAE,UAAU,CAAC,YAAY;SAC7B,CAAC,CAAC;QAEH,OAAO,iCAAiC,cAAc,6BAA6B,CAAC;IACtF,CAAC;CACF;AAED,UAAU,CAAC,UAAU,GAAG,UAAU,CAAC"}
@@ -0,0 +1,59 @@
1
+ import { delegate } from "@blazetrails/activesupport";
2
+ import { XML } from "@blazetrails/nokogiri";
3
+ import { toS } from "@blazetrails/ruby-compat";
4
+ import { ActionText } from "./action-text.js";
5
+ import { HtmlConversion } from "./html-conversion.js";
6
+ import { PlainTextConversion } from "./plain-text-conversion.js";
7
+ export class Fragment {
8
+ static wrap(fragmentOrHtml) {
9
+ if (fragmentOrHtml instanceof this) {
10
+ return fragmentOrHtml;
11
+ }
12
+ else if (fragmentOrHtml instanceof XML.DocumentFragment) {
13
+ return new this(fragmentOrHtml);
14
+ }
15
+ else {
16
+ return this.fromHtml(fragmentOrHtml);
17
+ }
18
+ }
19
+ static fromHtml(html) {
20
+ return new this(HtmlConversion.fragmentForHtml(toS(html).trim()));
21
+ }
22
+ source;
23
+ /** @internal */
24
+ plainText = null;
25
+ /** @internal */
26
+ html = null;
27
+ constructor(source) {
28
+ this.source = source;
29
+ }
30
+ findAll(selector) {
31
+ return this.source.css(selector);
32
+ }
33
+ async update(block) {
34
+ const source = this.source.dup();
35
+ await block(source);
36
+ return new this.constructor(source);
37
+ }
38
+ replace(selector, block) {
39
+ return this.update(async (source) => {
40
+ for (const node of source.css(selector).toA()) {
41
+ const replacementNode = await block(node);
42
+ if (!node.equals(replacementNode))
43
+ node.replace(String(replacementNode));
44
+ }
45
+ });
46
+ }
47
+ toPlainText() {
48
+ return (this.plainText ??= PlainTextConversion.nodeToPlainText(this.source));
49
+ }
50
+ toHtml() {
51
+ return (this.html ??= HtmlConversion.nodeToHtml(this.source));
52
+ }
53
+ toString() {
54
+ return this.toHtml();
55
+ }
56
+ }
57
+ delegate.call(Fragment.prototype, "deconstruct", { to: "source.elements" });
58
+ ActionText.Fragment = Fragment;
59
+ //# sourceMappingURL=fragment.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fragment.js","sourceRoot":"","sources":["../lib/fragment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AACtD,OAAO,EAAE,GAAG,EAA8C,MAAM,uBAAuB,CAAC;AACxF,OAAO,EAAE,GAAG,EAAE,MAAM,0BAA0B,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,MAAM,sBAA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GAAG,CAAC,QAAQ,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC;gBAC9C,MAAM,eAAe,GAAG,MAAM,KAAK,CAAC,IAAI,CAAC,CAAC;gBAC1C,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,eAAe,CAAC;oBAAE,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,eAAe,CAAC,CAAC,CAAC;YAC3E,CAAC;QACH,CAAC,CAAC,CAAC;IACL,CAAC;IAED,WAAW;QACT,OAAO,CAAC,IAAI,CAAC,SAAS,KAAK,mBAAmB,CAAC,eAAe,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;IAC/E,CAAC;IAED,MAAM;QACJ,OAAO,CAAC,IAAI,CAAC,IAAI,KAAK,cAAc,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;IAChE,CAAC;IAED,QAAQ;QACN,OAAO,IAAI,CAAC,MAAM,EAAE,CAAC;IACvB,CAAC;CACF;AAED,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,SAAS,EAAE,aAAa,EAAE,EAAE,EAAE,EAAE,iBAAiB,EAAE,CAAC,CAAC;AAE5E,UAAU,CAAC,QAAQ,GAAG,QAAQ,CAAC"}
@@ -0,0 +1,18 @@
1
+ import { Gem } from "@blazetrails/ruby-compat";
2
+ import { ActionText } from "./action-text.js";
3
+ export function gemVersion() {
4
+ return new Gem.Version(VERSION.STRING);
5
+ }
6
+ const MAJOR = 8;
7
+ const MINOR = 0;
8
+ const TINY = 5;
9
+ const PRE = "2";
10
+ export const VERSION = {
11
+ MAJOR,
12
+ MINOR,
13
+ TINY,
14
+ PRE,
15
+ STRING: [MAJOR, MINOR, TINY, PRE].filter((p) => p != null).join("."),
16
+ };
17
+ ActionText.gemVersion = gemVersion;
18
+ //# sourceMappingURL=gem-version.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gem-version.js","sourceRoot":"","sources":["../lib/gem-version.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,0BAA0B,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAE9C,MAAM,UAAU,UAAU;IACxB,OAAO,IAAI,GAAG,CAAC,OAAO,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;AACzC,CAAC;AAED,MAAM,KAAK,GAAG,CAAC,CAAC;AAChB,MAAM,KAAK,GAAG,CAAC,CAAC;AAChB,MAAM,IAAI,GAAG,CAAC,CAAC;AACf,MAAM,GAAG,GAAkB,GAAG,CAAC;AAE/B,MAAM,CAAC,MAAM,OAAO,GAAG;IACrB,KAAK;IACL,KAAK;IACL,IAAI;IACJ,GAAG;IACH,MAAM,EAAE,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,GAAG,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,IAAI,IAAI,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC;CACrE,CAAC;AAEF,UAAU,CAAC,UAAU,GAAG,UAAU,CAAC"}
@@ -0,0 +1,88 @@
1
+ import "../../../constants.action-text-install-install-generator.generated.js";
2
+ import { File, Pathname } from "@blazetrails/ruby-compat";
3
+ import { Base } from "@blazetrails/trailties/generators";
4
+ const __dir__ = File.dirname(decodeURIComponent(new URL(import.meta.url).pathname));
5
+ export class InstallGenerator extends Base {
6
+ static {
7
+ this.methodAdded("installJavascriptDependencies");
8
+ this.methodAdded("appendJavascriptDependencies");
9
+ this.methodAdded("createActiontextFiles");
10
+ this.methodAdded("enableImageProcessingGem");
11
+ this.methodAdded("createMigrations");
12
+ this.methodAdded("isUsingJsRuntime");
13
+ this.methodAdded("isUsingBun");
14
+ this.methodAdded("isUsingNode");
15
+ }
16
+ /** @internal */
17
+ _usingJsRuntime;
18
+ /** @internal */
19
+ _usingBun;
20
+ /** @internal */
21
+ _usingNode;
22
+ /** @missingRailsArgs run — PERMANENT */
23
+ async installJavascriptDependencies() {
24
+ this.say("Installing JavaScript dependencies", "green");
25
+ if (await this.isUsingBun()) {
26
+ await this.run("bun add @rails/actiontext trix");
27
+ }
28
+ else if (await this.isUsingNode()) {
29
+ await this.run("pnpm add @rails/actiontext trix");
30
+ }
31
+ }
32
+ async appendJavascriptDependencies() {
33
+ const destination = this.destinationRoot;
34
+ const applicationJavascriptPath = File.join(destination, "app/javascript/application.js");
35
+ if (await File.isExistAsync(applicationJavascriptPath)) {
36
+ await this.insertIntoFile(applicationJavascriptPath, `\nimport "trix"\nimport "@rails/actiontext"\n`);
37
+ }
38
+ else {
39
+ this.say("You must import the @rails/actiontext and trix JavaScript modules in your application entrypoint.\n", "green");
40
+ }
41
+ const importmapPath = File.join(destination, "config/importmap.rb");
42
+ if (await File.isExistAsync(importmapPath)) {
43
+ await this.appendToFile(importmapPath, `pin "trix"\npin "@rails/actiontext", to: "actiontext.esm.js"\n`);
44
+ }
45
+ }
46
+ async createActiontextFiles() {
47
+ await this.template("actiontext.css", "app/assets/stylesheets/actiontext.css");
48
+ const gemRoot = `${__dir__}/../../../..`;
49
+ await this.copyFile(`${gemRoot}/app/views/active-storage/blobs/_blob.html.tse`, "app/views/active-storage/blobs/_blob.html.tse");
50
+ await this.copyFile(`${gemRoot}/app/views/layouts/action-text/contents/_content.html.tse`, "app/views/layouts/action-text/contents/_content.html.tse");
51
+ }
52
+ async enableImageProcessingGem() {
53
+ const gemfilePath = new Pathname(this.destinationRoot).join("package.json");
54
+ if (await File.isExistAsync(gemfilePath.toPath())) {
55
+ this.say("Ensure image_processing gem has been enabled so image uploads will work (remember to bundle!)");
56
+ const imageProcessingRegex = /"@blazetrails\/image-processing"/;
57
+ if ((await File.readlinesAsync(gemfilePath.toPath())).filter((l) => imageProcessingRegex.test(l)).length > 0) {
58
+ await this.uncommentLines(gemfilePath, imageProcessingRegex);
59
+ }
60
+ else {
61
+ await this.gem("@blazetrails/image-processing");
62
+ }
63
+ }
64
+ }
65
+ async createMigrations() {
66
+ await this.trailsCommand("railties:install:migrations FROM=active_storage,action_text", {
67
+ inline: true,
68
+ });
69
+ }
70
+ async isUsingJsRuntime() {
71
+ return (this._usingJsRuntime ||= await File.isExistAsync(new Pathname(this.destinationRoot).join("package.json").toPath()));
72
+ }
73
+ async isUsingBun() {
74
+ return (this._usingBun ||=
75
+ (await this.isUsingJsRuntime()) &&
76
+ (await File.isExistAsync(new Pathname(this.destinationRoot).join("bun.config.js").toPath())));
77
+ }
78
+ async isUsingNode() {
79
+ return (this._usingNode ||=
80
+ (await this.isUsingJsRuntime()) &&
81
+ !(await File.isExistAsync(new Pathname(this.destinationRoot).join("bun.config.js").toPath())));
82
+ }
83
+ static {
84
+ this.hookFor("testFramework");
85
+ }
86
+ }
87
+ InstallGenerator.sourceRoot(File.expandPath("templates", __dir__));
88
+ //# sourceMappingURL=install-generator.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"install-generator.js","sourceRoot":"","sources":["../../../../lib/generators/action-text/install/install-generator.ts"],"names":[],"mappings":"AAAA,OAAO,uEAAuE,CAAC;AAC/E,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAE1D,OAAO,EAAE,IAAI,EAAE,MAAM,mCAAmC,CAAC;AAEzD,MAAM,OAAO,GAAG,IAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC,IAAI,GAAG,CAAC,OAAO,IAAI,CAAC,GAAG,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;AAEpF,MAAM,OAAO,gBAAiB,SAAQ,IAAI;IACxC;QACE,IAAI,CAAC,WAAW,CAAC,+BAA+B,CAAC,CAAC;QAClD,IAAI,CAAC,WAAW,CAAC,8BAA8B,CAAC,CAAC;QACjD,IAAI,CAAC,WAAW,CAAC,uBAAuB,CAAC,CAAC;QAC1C,IAAI,CAAC,WAAW,CAAC,0BAA0B,CAAC,CAAC;QAC7C,IAAI,CAAC,WAAW,CAAC,kBAAkB,CAAC,CAAC;QACrC,IAAI,CAAC,WAAW,CAAC,kB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