Skip to content

Commit

Permalink
Turbo v8.0.4
Browse files Browse the repository at this point in the history
  • Loading branch information
afcapel committed Mar 8, 2024
1 parent e8dd34a commit ed7955d
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 29 deletions.
28 changes: 9 additions & 19 deletions app/assets/javascripts/turbo.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
Turbo 8.0.3
Turbo 8.0.4
Copyright © 2024 37signals LLC
*/
(function(prototype) {
Expand Down Expand Up @@ -72,7 +72,7 @@ class FrameElement extends HTMLElement {
static delegateConstructor=undefined;
loaded=Promise.resolve();
static get observedAttributes() {
return [ "disabled", "complete", "loading", "src" ];
return [ "disabled", "loading", "src" ];
}
constructor() {
super();
Expand All @@ -90,11 +90,9 @@ class FrameElement extends HTMLElement {
attributeChangedCallback(name) {
if (name == "loading") {
this.delegate.loadingStyleChanged();
} else if (name == "complete") {
this.delegate.completeChanged();
} else if (name == "src") {
this.delegate.sourceURLChanged();
} else {
} else if (name == "disabled") {
this.delegate.disabledChanged();
}
}
Expand Down Expand Up @@ -4561,17 +4559,11 @@ class FrameController {
}
sourceURLReloaded() {
const {src: src} = this.element;
this.#ignoringChangesToAttribute("complete", (() => {
this.element.removeAttribute("complete");
}));
this.element.removeAttribute("complete");
this.element.src = null;
this.element.src = src;
return this.element.loaded;
}
completeChanged() {
if (this.#isIgnoringChangesTo("complete")) return;
this.#loadSourceURL();
}
loadingStyleChanged() {
if (this.loadingStyle == FrameLoadingStyle.lazy) {
this.appearanceObserver.start();
Expand Down Expand Up @@ -4903,13 +4895,11 @@ class FrameController {
return this.element.hasAttribute("complete");
}
set complete(value) {
this.#ignoringChangesToAttribute("complete", (() => {
if (value) {
this.element.setAttribute("complete", "");
} else {
this.element.removeAttribute("complete");
}
}));
if (value) {
this.element.setAttribute("complete", "");
} else {
this.element.removeAttribute("complete");
}
}
get isActive() {
return this.element.isActive && this.#connected;
Expand Down
6 changes: 3 additions & 3 deletions app/assets/javascripts/turbo.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion app/assets/javascripts/turbo.min.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@hotwired/turbo-rails",
"version": "8.0.3",
"version": "8.0.4",
"description": "The speed of a single-page web application without having to write any JavaScript",
"module": "app/javascript/turbo/index.js",
"main": "app/assets/javascripts/turbo.js",
Expand All @@ -13,7 +13,7 @@
"release": "npm publish && git commit -am \"$npm_package_name v$npm_package_version\" && git push"
},
"dependencies": {
"@hotwired/turbo": "^8.0.3",
"@hotwired/turbo": "^8.0.4",
"@rails/actioncable": "^7.0"
},
"devDependencies": {
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@
chalk "^2.4.2"
js-tokens "^4.0.0"

"@hotwired/turbo@^8.0.3":
version "8.0.3"
resolved "https://registry.yarnpkg.com/@hotwired/turbo/-/turbo-8.0.3.tgz#338e07278f4b3c76921328d3c92dbc4831c209d0"
integrity sha512-qLgp7d6JaegKjMToTJahosrFxV3odfSbiekispQ3soOzE5jnU+iEMWlRvYRe/jvy5Q+JWoywtf9j3RD4ikVjIg==
"@hotwired/turbo@^8.0.4":
version "8.0.4"
resolved "https://registry.yarnpkg.com/@hotwired/turbo/-/turbo-8.0.4.tgz#5c5361c06a37cdf10dcba4223f1afd0ca1c75091"
integrity sha512-mlZEFUZrJnpfj+g/XeCWWuokvQyN68WvM78JM+0jfSFc98wegm259vCbC1zSllcspRwbgXK31ibehCy5PA78/Q==

"@jridgewell/gen-mapping@^0.3.0":
version "0.3.3"
Expand Down

0 comments on commit ed7955d

Please sign in to comment.