@rails/actiontext 7.0.0-alpha2 → 7.0.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.
|
@@ -4,7 +4,7 @@ export class AttachmentUpload {
|
|
|
4
4
|
constructor(attachment, element) {
|
|
5
5
|
this.attachment = attachment
|
|
6
6
|
this.element = element
|
|
7
|
-
this.directUpload = new DirectUpload(attachment.file, this.directUploadUrl, this)
|
|
7
|
+
this.directUpload = new DirectUpload(attachment.file, this.directUploadUrl, this.directUploadToken, this.attachmentName, this)
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
start() {
|
|
@@ -42,4 +42,11 @@ export class AttachmentUpload {
|
|
|
42
42
|
get blobUrlTemplate() {
|
|
43
43
|
return this.element.dataset.blobUrlTemplate
|
|
44
44
|
}
|
|
45
|
+
|
|
46
|
+
get directUploadToken() {
|
|
47
|
+
return this.element.getAttribute("data-direct-upload-token");
|
|
48
|
+
}
|
|
49
|
+
get attachmentName() {
|
|
50
|
+
return this.element.getAttribute("data-direct-upload-attachment-name");
|
|
51
|
+
}
|
|
45
52
|
}
|
package/package.json
CHANGED
package/CHANGELOG.md
DELETED
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
## Rails 7.0.0.alpha2 (September 15, 2021) ##
|
|
2
|
-
|
|
3
|
-
* No changes.
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
## Rails 7.0.0.alpha1 (September 15, 2021) ##
|
|
7
|
-
|
|
8
|
-
* Make the Action Text + Trix JavaScript and CSS available through the asset pipeline.
|
|
9
|
-
|
|
10
|
-
*DHH*
|
|
11
|
-
|
|
12
|
-
* OpenSSL constants are now used for Digest computations.
|
|
13
|
-
|
|
14
|
-
*Dirkjan Bussink*
|
|
15
|
-
|
|
16
|
-
* Add support for passing `form:` option to `rich_text_area_tag` and
|
|
17
|
-
`rich_text_area` helpers to specify the `<input type="hidden" form="...">`
|
|
18
|
-
value.
|
|
19
|
-
|
|
20
|
-
*Sean Doyle*
|
|
21
|
-
|
|
22
|
-
* Add `config.action_text.attachment_tag_name`, to specify the HTML tag that contains attachments.
|
|
23
|
-
|
|
24
|
-
*Mark VanLandingham*
|
|
25
|
-
|
|
26
|
-
* Expose how we render the HTML _surrounding_ rich text content as an
|
|
27
|
-
extensible `layouts/action_view/contents/_content.html.erb` template to
|
|
28
|
-
encourage user-land customizations, while retaining private API control over how
|
|
29
|
-
the rich text itself is rendered by `action_text/contents/_content.html.erb`
|
|
30
|
-
partial.
|
|
31
|
-
|
|
32
|
-
*Sean Doyle*
|
|
33
|
-
|
|
34
|
-
* Add `with_all_rich_text` method to eager load all rich text associations on a model at once.
|
|
35
|
-
|
|
36
|
-
*Matt Swanson*, *DHH*
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
Please check [6-1-stable](https://github.com/rails/rails/blob/6-1-stable/actiontext/CHANGELOG.md) for previous changes.
|