@visitscotland/component-library 4.7.3 → 4.7.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/CHANGELOG.md CHANGED
@@ -2,6 +2,13 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [4.7.4](https://github.com/visitscotland/vs-component-library/compare/v4.7.3...v4.7.4) (2025-01-20)
6
+
7
+
8
+ ### 🐛 Bug Fixes
9
+
10
+ * **back to top:** button positioning ([a39d48a](https://github.com/visitscotland/vs-component-library/commit/a39d48af067d74f87a786b08ebef012985ca9581))
11
+
5
12
  ### [4.7.3](https://github.com/visitscotland/vs-component-library/compare/v4.7.2...v4.7.3) (2025-01-20)
6
13
 
7
14
 
@@ -341,12 +341,12 @@
341
341
  "scripts/63d29726a2e5382258a4.js",
342
342
  "scripts/206ec6607e492acd68be.js",
343
343
  "scripts/0fca23adffd3007411e5.js",
344
- "scripts/19f1e6f2e81f81d82109.js"
344
+ "scripts/cdd935c138f36a748f8e.js"
345
345
  ],
346
346
  "styles": [
347
347
  "styles/63d29726a2e5382258a4.css",
348
348
  "styles/0fca23adffd3007411e5.css",
349
- "styles/19f1e6f2e81f81d82109.css"
349
+ "styles/cdd935c138f36a748f8e.css"
350
350
  ]
351
351
  },
352
352
  "VsVsBadge": {
@@ -1 +1 @@
1
- !function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.VsBackToTop=n():t.VsBackToTop=n()}(self,(function(){return(self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[9853],{43026:function(){},74052:function(t,n,e){"use strict";var o=e(20641),r=e(90033),u=e(50953),i=e(48836),c={class:"vs-back-to-top","data-test":"vs-back-to-top"};n.A={__name:"BackToTop",props:{buttonText:{type:String,required:!0},offset:{type:Number,default:100}},setup:function(t){var n=t,e=(0,u.KR)(!1),s=function(){var t=document.documentElement;(window.scrollY||t.scrollTop)-(t.clientTop||0)>n.offset?e.value=!0:e.value=!1},a=function(t){window.scroll({top:0,behavior:"smooth"}),t.target.blur()};return(0,o.sV)((function(){window.addEventListener("scroll",s)})),(0,o.hi)((function(){window.removeEventListener("scroll",s)})),function(t,u){return(0,o.uX)(),(0,o.CE)("div",c,[e.value?((0,o.uX)(),(0,o.Wv)(i.default,{key:0,icon:"arrow-up","icon-only":"",variant:"secondary",onClick:a},{default:(0,o.k6)((function(){return[(0,o.eW)((0,r.toDisplayString)(n.buttonText),1)]})),_:1})):(0,o.Q3)("",!0)])}}}},64208:function(t,n,e){"use strict";var o=e(85072),r=e.n(o),u=e(97825),i=e.n(u),c=e(77659),s=e.n(c),a=e(55056),l=e.n(a),f=e(10540),d=e.n(f),p=e(41113),v=e.n(p),b=e(43026),m=e.n(b),y={};y.styleTagTransform=v(),y.setAttributes=l(),y.insert=s().bind(null,"head"),y.domAPI=i(),y.insertStyleElement=d(),r()(m(),y),m()&&m().locals&&m().locals},54670:function(t,n,e){"use strict";e.r(n);var o=e(38880);e(72052);const r=o.A;n.default=r},38880:function(t,n,e){"use strict";e.d(n,{A:function(){return o.A}});var o=e(74052)},72052:function(t,n,e){"use strict";e(64208)}},function(t){return t.O(0,[641,6262,7510,3751,4352,4467,7527,8086,810,6422,8745,8836],(function(){return t(t.s=54670)})),t.O()}])}));
1
+ !function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.VsBackToTop=n():t.VsBackToTop=n()}(self,(function(){return(self.webpackChunk_visitscotland_component_library=self.webpackChunk_visitscotland_component_library||[]).push([[9853],{43114:function(){},74052:function(t,n,e){"use strict";var o=e(20641),r=e(90033),u=e(50953),i=e(48836),c={class:"vs-back-to-top","data-test":"vs-back-to-top"};n.A={__name:"BackToTop",props:{buttonText:{type:String,required:!0},offset:{type:Number,default:100}},setup:function(t){var n=t,e=(0,u.KR)(!1),s=function(){var t=document.documentElement;(window.scrollY||t.scrollTop)-(t.clientTop||0)>n.offset?e.value=!0:e.value=!1},a=function(t){window.scroll({top:0,behavior:"smooth"}),t.target.blur()};return(0,o.sV)((function(){window.addEventListener("scroll",s)})),(0,o.hi)((function(){window.removeEventListener("scroll",s)})),function(t,u){return(0,o.uX)(),(0,o.CE)("div",c,[e.value?((0,o.uX)(),(0,o.Wv)(i.default,{key:0,icon:"arrow-up","icon-only":"",variant:"secondary",onClick:a},{default:(0,o.k6)((function(){return[(0,o.eW)((0,r.toDisplayString)(n.buttonText),1)]})),_:1})):(0,o.Q3)("",!0)])}}}},31140:function(t,n,e){"use strict";var o=e(85072),r=e.n(o),u=e(97825),i=e.n(u),c=e(77659),s=e.n(c),a=e(55056),l=e.n(a),f=e(10540),d=e.n(f),p=e(41113),v=e.n(p),b=e(43114),m=e.n(b),y={};y.styleTagTransform=v(),y.setAttributes=l(),y.insert=s().bind(null,"head"),y.domAPI=i(),y.insertStyleElement=d(),r()(m(),y),m()&&m().locals&&m().locals},54670:function(t,n,e){"use strict";e.r(n);var o=e(38880);e(5016);const r=o.A;n.default=r},38880:function(t,n,e){"use strict";e.d(n,{A:function(){return o.A}});var o=e(74052)},5016:function(t,n,e){"use strict";e(31140)}},function(t){return t.O(0,[641,6262,7510,3751,4352,4467,7527,8086,810,6422,8745,8836],(function(){return t(t.s=54670)})),t.O()}])}));
@@ -0,0 +1 @@
1
+ .vs-back-to-top{display:flex;inset-block-end:1rem;position:sticky}.vs-back-to-top .vs-button{margin:-4rem 1rem 0 auto}.no-js .vs-back-to-top{display:none !important}