@justeat/f-button
Advanced tools
Comparing version 1.6.1 to 1.7.0
@@ -6,3 +6,10 @@ # Changelog | ||
v1.7.0 | ||
------------------------------ | ||
*June 15, 2021* | ||
### Added | ||
- Support for Vue Router link and tests | ||
v1.6.1 | ||
@@ -9,0 +16,0 @@ ------------------------------ |
@@ -122,3 +122,3 @@ module.exports = | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Button.vue?vue&type=template&id=20a79d7b& | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Button.vue?vue&type=template&id=eaa536d8& | ||
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c(_vm.componentType,_vm._g(_vm._b({tag:"component",class:[ | ||
@@ -138,5 +138,5 @@ _vm.$style['o-btn'], | ||
// CONCATENATED MODULE: ./src/components/Button.vue?vue&type=template&id=20a79d7b& | ||
// CONCATENATED MODULE: ./src/components/Button.vue?vue&type=template&id=eaa536d8& | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Action.vue?vue&type=template&id=5e41886b& | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Action.vue?vue&type=template&id=5e41886b& | ||
var Actionvue_type_template_id_5e41886b_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('button',_vm._g({attrs:{"type":_vm.actionType}},_vm.$listeners),[_vm._t("default")],2)} | ||
@@ -148,3 +148,3 @@ var Actionvue_type_template_id_5e41886b_staticRenderFns = [] | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--12-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/thread-loader/dist/cjs.js!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Action.vue?vue&type=script&lang=js& | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--12-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/thread-loader/dist/cjs.js!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Action.vue?vue&type=script&lang=js& | ||
// | ||
@@ -168,3 +168,3 @@ // | ||
/* harmony default export */ var components_Actionvue_type_script_lang_js_ = (Actionvue_type_script_lang_js_); | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/runtime/componentNormalizer.js | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/runtime/componentNormalizer.js | ||
/* globals __VUE_SSR_CONTEXT__ */ | ||
@@ -289,3 +289,3 @@ | ||
/* harmony default export */ var Action = (component.exports); | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Link.vue?vue&type=template&id=1356d3f1& | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Link.vue?vue&type=template&id=1356d3f1& | ||
var Linkvue_type_template_id_1356d3f1_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('a',[_vm._t("default")],2)} | ||
@@ -316,3 +316,3 @@ var Linkvue_type_template_id_1356d3f1_staticRenderFns = [] | ||
/* harmony default export */ var Link = (Link_component.exports); | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--12-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/thread-loader/dist/cjs.js!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Button.vue?vue&type=script&lang=js& | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--12-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/thread-loader/dist/cjs.js!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Button.vue?vue&type=script&lang=js& | ||
// | ||
@@ -399,13 +399,22 @@ // | ||
* Renders `Link` component if a `href` attribute is applied to the component | ||
* Renders `Action` component if no `href` attribute is applied to the component | ||
* Renders `RouterLink` component if a `to` attribute is applied to the component, avoids page reload compared to Link with `href` | ||
* Renders `Action` component if no `href` attrivute is applied to the component | ||
*/ | ||
componentType: function componentType() { | ||
return this.$attrs.href ? 'link-button' : 'action-button'; | ||
if (this.$attrs.href) { | ||
return 'link-button'; | ||
} | ||
if (this.$attrs.to) { | ||
return 'router-link'; | ||
} | ||
return 'action-button'; | ||
}, | ||
/** | ||
* Passes `actionType` prop to action button if no `href` attribute is applied to the component | ||
* Passes `actionType` prop to action button if no `href` or `to` attributes is applied to the component | ||
*/ | ||
buttonActionType: function buttonActionType() { | ||
return !this.$attrs.href ? this.actionType : null; | ||
return !this.$attrs.href && !this.$attrs.to ? this.actionType : null; | ||
}, | ||
@@ -610,3 +619,3 @@ | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js | ||
// This file is imported into lib/wc client bundles. | ||
@@ -638,3 +647,3 @@ | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/lib/commands/build/entry-lib.js | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/lib/commands/build/entry-lib.js | ||
/* concated harmony reexport install */__webpack_require__.d(__webpack_exports__, "install", function() { return src_0["b" /* install */]; }); | ||
@@ -641,0 +650,0 @@ |
@@ -131,3 +131,3 @@ (function webpackUniversalModuleDefinition(root, factory) { | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Button.vue?vue&type=template&id=20a79d7b& | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Button.vue?vue&type=template&id=eaa536d8& | ||
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c(_vm.componentType,_vm._g(_vm._b({tag:"component",class:[ | ||
@@ -147,5 +147,5 @@ _vm.$style['o-btn'], | ||
// CONCATENATED MODULE: ./src/components/Button.vue?vue&type=template&id=20a79d7b& | ||
// CONCATENATED MODULE: ./src/components/Button.vue?vue&type=template&id=eaa536d8& | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Action.vue?vue&type=template&id=5e41886b& | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Action.vue?vue&type=template&id=5e41886b& | ||
var Actionvue_type_template_id_5e41886b_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('button',_vm._g({attrs:{"type":_vm.actionType}},_vm.$listeners),[_vm._t("default")],2)} | ||
@@ -157,3 +157,3 @@ var Actionvue_type_template_id_5e41886b_staticRenderFns = [] | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--12-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/thread-loader/dist/cjs.js!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Action.vue?vue&type=script&lang=js& | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--12-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/thread-loader/dist/cjs.js!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Action.vue?vue&type=script&lang=js& | ||
// | ||
@@ -177,3 +177,3 @@ // | ||
/* harmony default export */ var components_Actionvue_type_script_lang_js_ = (Actionvue_type_script_lang_js_); | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/runtime/componentNormalizer.js | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/runtime/componentNormalizer.js | ||
/* globals __VUE_SSR_CONTEXT__ */ | ||
@@ -298,3 +298,3 @@ | ||
/* harmony default export */ var Action = (component.exports); | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Link.vue?vue&type=template&id=1356d3f1& | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"6276e5c9-vue-loader-template"}!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Link.vue?vue&type=template&id=1356d3f1& | ||
var Linkvue_type_template_id_1356d3f1_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('a',[_vm._t("default")],2)} | ||
@@ -325,3 +325,3 @@ var Linkvue_type_template_id_1356d3f1_staticRenderFns = [] | ||
/* harmony default export */ var Link = (Link_component.exports); | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--12-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/thread-loader/dist/cjs.js!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Button.vue?vue&type=script&lang=js& | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--12-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/thread-loader/dist/cjs.js!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-plugin-babel/node_modules/babel-loader/lib!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/cache-loader/dist/cjs.js??ref--0-0!/Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/node_modules/vue-loader/lib??vue-loader-options!./src/components/Button.vue?vue&type=script&lang=js& | ||
// | ||
@@ -408,13 +408,22 @@ // | ||
* Renders `Link` component if a `href` attribute is applied to the component | ||
* Renders `Action` component if no `href` attribute is applied to the component | ||
* Renders `RouterLink` component if a `to` attribute is applied to the component, avoids page reload compared to Link with `href` | ||
* Renders `Action` component if no `href` attrivute is applied to the component | ||
*/ | ||
componentType: function componentType() { | ||
return this.$attrs.href ? 'link-button' : 'action-button'; | ||
if (this.$attrs.href) { | ||
return 'link-button'; | ||
} | ||
if (this.$attrs.to) { | ||
return 'router-link'; | ||
} | ||
return 'action-button'; | ||
}, | ||
/** | ||
* Passes `actionType` prop to action button if no `href` attribute is applied to the component | ||
* Passes `actionType` prop to action button if no `href` or `to` attributes is applied to the component | ||
*/ | ||
buttonActionType: function buttonActionType() { | ||
return !this.$attrs.href ? this.actionType : null; | ||
return !this.$attrs.href && !this.$attrs.to ? this.actionType : null; | ||
}, | ||
@@ -619,3 +628,3 @@ | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js | ||
// This file is imported into lib/wc client bundles. | ||
@@ -647,3 +656,3 @@ | ||
// CONCATENATED MODULE: /Users/ashley.nolan/_je/ui/components/fozzie-components/node_modules/@vue/cli-service/lib/commands/build/entry-lib.js | ||
// CONCATENATED MODULE: /Users/zlatin.ivanov/Documents/justeat/fozzie-components/node_modules/@vue/cli-service/lib/commands/build/entry-lib.js | ||
/* concated harmony reexport install */__webpack_require__.d(__webpack_exports__, "install", function() { return src_0["b" /* install */]; }); | ||
@@ -650,0 +659,0 @@ |
@@ -1,2 +0,2 @@ | ||
(function(t,n){"object"===typeof exports&&"object"===typeof module?module.exports=n():"function"===typeof define&&define.amd?define([],n):"object"===typeof exports?exports["f-button"]=n():t["f-button"]=n()})("undefined"!==typeof self?self:this,(function(){return function(t){var n={};function e(o){if(n[o])return n[o].exports;var r=n[o]={i:o,l:!1,exports:{}};return t[o].call(r.exports,r,r.exports,e),r.l=!0,r.exports}return e.m=t,e.c=n,e.d=function(t,n,o){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:o})},e.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n)return t;if(4&n&&"object"===typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(e.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var r in t)e.d(o,r,function(n){return t[n]}.bind(null,r));return o},e.n=function(t){var n=t&&t.__esModule?function(){return t["default"]}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},e.p="",e(e.s="fa16")}({"05e9":function(t,n){var e;e=function(){return this}();try{e=e||new Function("return this")()}catch(o){"object"===typeof window&&(e=window)}t.exports=e},"2a7d":function(t,n,e){"use strict";var o=function(){var t=this,n=t.$createElement,e=t._self._c||n;return e(t.componentType,t._g(t._b({tag:"component",class:[t.$style["o-btn"],t.isIcon?t.$style["o-btn--icon"]:"",t.$style["o-btn--"+t.buttonType],t.$style["o-btn--size"+t.buttonSizeClassname],t.isFullWidth?t.$style["o-btn--fullWidth"]:"",t.isLoading?t.$style["o-btn--loading"]:""],attrs:{"action-type":t.buttonActionType,"data-test-id":t.componentType+"-component","aria-live":t.getAriaLive,"aria-busy":t.isLoading}},"component",t.$attrs,!1),!t.isLoading&&t.$listeners),[t.isLoading?e("span",{class:t.$style["c-spinner"],attrs:{"data-test-id":t.componentType+"-spinner"}}):t._e(),e("span",{class:[t.$style["o-btn-text"],t.isLoading?t.$style["o-btn-text--hidden"]:""]},[t._t("default")],2)])},r=[],i=function(){var t=this,n=t.$createElement,e=t._self._c||n;return e("button",t._g({attrs:{type:t.actionType}},t.$listeners),[t._t("default")],2)},u=[],s={props:{actionType:{type:String,required:!0}}},c=s;function a(t,n,e,o,r,i,u,s){var c,a="function"===typeof t?t.options:t;if(n&&(a.render=n,a.staticRenderFns=e,a._compiled=!0),o&&(a.functional=!0),i&&(a._scopeId="data-v-"+i),u?(c=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),r&&r.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(u)},a._ssrRegister=c):r&&(c=s?function(){r.call(this,(a.functional?this.parent:this).$root.$options.shadowRoot)}:r),c)if(a.functional){a._injectStyles=c;var l=a.render;a.render=function(t,n){return c.call(n),l(t,n)}}else{var d=a.beforeCreate;a.beforeCreate=d?[].concat(d,c):[c]}return{exports:t,options:a}}var l=a(c,i,u,!1,null,null,null),d=l.exports,f=function(){var t=this,n=t.$createElement,e=t._self._c||n;return e("a",[t._t("default")],2)},p=[],b={},_=a(b,f,p,!1,null,null,null),y=_.exports,m={name:"FButton",components:{ActionButton:d,LinkButton:y},props:{buttonType:{type:String,default:"primary"},buttonSize:{type:String,default:"medium"},isFullWidth:{type:Boolean,default:!1},actionType:{type:String,default:"button"},isIcon:{type:Boolean,default:!1},isLoading:{type:Boolean,default:!1}},computed:{buttonSizeClassname:function(){return"xsmall"===this.buttonSize?this.buttonSize.slice(0,2).toUpperCase()+this.buttonSize.slice(2):this.buttonSize.charAt(0).toUpperCase()+this.buttonSize.slice(1)},componentType:function(){return this.$attrs.href?"link-button":"action-button"},buttonActionType:function(){return this.$attrs.href?null:this.actionType},getAriaLive:function(){return this.isLoading?"polite":"off"}}},h=m,g=e("4e4b");function v(t){this["$style"]=g["default"].locals||g["default"]}var S=a(h,o,r,!1,v,null,null);n["a"]=S.exports},"4e4b":function(t,n,e){"use strict";var o=e("9a8d"),r=e.n(o);e.d(n,"default",(function(){return r.a}))},"7e10":function(t,n,e){var o,r,i;(function(e,u){r=[],o=u,i="function"===typeof o?o.apply(n,r):o,void 0===i||(t.exports=i)})("undefined"!==typeof self&&self,(function(){function t(){var n=Object.getOwnPropertyDescriptor(document,"currentScript");if(!n&&"currentScript"in document&&document.currentScript)return document.currentScript;if(n&&n.get!==t&&document.currentScript)return document.currentScript;try{throw new Error}catch(p){var e,o,r,i=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,u=/@([^@]*):(\d+):(\d+)\s*$/gi,s=i.exec(p.stack)||u.exec(p.stack),c=s&&s[1]||!1,a=s&&s[2]||!1,l=document.location.href.replace(document.location.hash,""),d=document.getElementsByTagName("script");c===l&&(e=document.documentElement.outerHTML,o=new RegExp("(?:[^\\n]+?\\n){0,"+(a-2)+"}[^<]*<script>([\\d\\D]*?)<\\/script>[\\d\\D]*","i"),r=e.replace(o,"$1").trim());for(var f=0;f<d.length;f++){if("interactive"===d[f].readyState)return d[f];if(d[f].src===c)return d[f];if(c===l&&d[f].innerHTML&&d[f].innerHTML.trim()===r)return d[f]}return null}}return t}))},"9a8d":function(t,n,e){t.exports={"c-screen-sizer":"Button_c-screen-sizer_aacnl","c-spinner-wrapper":"Button_c-spinner-wrapper_16dYe","c-spinner":"Button_c-spinner_16ib0",spin:"Button_spin_1l7_1","o-btn":"Button_o-btn_1KX8u","o-btnLink":"Button_o-btnLink_MQkN7","o-btn-text":"Button_o-btn-text_3sVkf","o-btn-text--hidden":"Button_o-btn-text--hidden_6AbPr","o-btn--primary":"Button_o-btn--primary_NRuBe","o-btn--icon":"Button_o-btn--icon_1k-qM","o-btn--sizeLarge":"Button_o-btn--sizeLarge_3A8Ov","o-btn--loading":"Button_o-btn--loading_2up-7","o-btn--secondary":"Button_o-btn--secondary_1KBR1","o-btn--outline":"Button_o-btn--outline_3TR6n","o-btn--ghost":"Button_o-btn--ghost_1hnGu","o-btn--link":"Button_o-btn--link_2f-eF","o-btn--sizeMedium":"Button_o-btn--sizeMedium_2uSln","o-btn--sizeSmall":"Button_o-btn--sizeSmall_WNBZx","o-btn--sizeXSmall":"Button_o-btn--sizeXSmall_3KRtq","o-btn--fullWidth":"Button_o-btn--fullWidth_1xkfh","is-disabled":"Button_is-disabled_1zPQV",skeletonGradient:"Button_skeletonGradient_2l0Iq"}},b635:function(t,n,e){"use strict";(function(t){e.d(n,"b",(function(){return r}));var o=e("2a7d");function r(t){r.installed||(r.installed=!0,t.component("FButton",o["a"]))}var i={install:r},u=null;"undefined"!==typeof window?u=window.Vue:"undefined"!==typeof t&&(u=t.Vue),u&&u.use(i),n["a"]=o["a"]}).call(this,e("05e9"))},fa16:function(t,n,e){"use strict";if(e.r(n),"undefined"!==typeof window){var o=window.document.currentScript,r=e("7e10");o=r(),"currentScript"in document||Object.defineProperty(document,"currentScript",{get:r});var i=o&&o.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);i&&(e.p=i[1])}var u=e("b635");e.d(n,"install",(function(){return u["b"]}));n["default"]=u["a"]}})})); | ||
(function(t,n){"object"===typeof exports&&"object"===typeof module?module.exports=n():"function"===typeof define&&define.amd?define([],n):"object"===typeof exports?exports["f-button"]=n():t["f-button"]=n()})("undefined"!==typeof self?self:this,(function(){return function(t){var n={};function e(o){if(n[o])return n[o].exports;var r=n[o]={i:o,l:!1,exports:{}};return t[o].call(r.exports,r,r.exports,e),r.l=!0,r.exports}return e.m=t,e.c=n,e.d=function(t,n,o){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:o})},e.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n)return t;if(4&n&&"object"===typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(e.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var r in t)e.d(o,r,function(n){return t[n]}.bind(null,r));return o},e.n=function(t){var n=t&&t.__esModule?function(){return t["default"]}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},e.p="",e(e.s="fa16")}({"05e9":function(t,n){var e;e=function(){return this}();try{e=e||new Function("return this")()}catch(o){"object"===typeof window&&(e=window)}t.exports=e},"2a7d":function(t,n,e){"use strict";var o=function(){var t=this,n=t.$createElement,e=t._self._c||n;return e(t.componentType,t._g(t._b({tag:"component",class:[t.$style["o-btn"],t.isIcon?t.$style["o-btn--icon"]:"",t.$style["o-btn--"+t.buttonType],t.$style["o-btn--size"+t.buttonSizeClassname],t.isFullWidth?t.$style["o-btn--fullWidth"]:"",t.isLoading?t.$style["o-btn--loading"]:""],attrs:{"action-type":t.buttonActionType,"data-test-id":t.componentType+"-component","aria-live":t.getAriaLive,"aria-busy":t.isLoading}},"component",t.$attrs,!1),!t.isLoading&&t.$listeners),[t.isLoading?e("span",{class:t.$style["c-spinner"],attrs:{"data-test-id":t.componentType+"-spinner"}}):t._e(),e("span",{class:[t.$style["o-btn-text"],t.isLoading?t.$style["o-btn-text--hidden"]:""]},[t._t("default")],2)])},r=[],i=function(){var t=this,n=t.$createElement,e=t._self._c||n;return e("button",t._g({attrs:{type:t.actionType}},t.$listeners),[t._t("default")],2)},u=[],s={props:{actionType:{type:String,required:!0}}},a=s;function c(t,n,e,o,r,i,u,s){var a,c="function"===typeof t?t.options:t;if(n&&(c.render=n,c.staticRenderFns=e,c._compiled=!0),o&&(c.functional=!0),i&&(c._scopeId="data-v-"+i),u?(a=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),r&&r.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(u)},c._ssrRegister=a):r&&(a=s?function(){r.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:r),a)if(c.functional){c._injectStyles=a;var l=c.render;c.render=function(t,n){return a.call(n),l(t,n)}}else{var d=c.beforeCreate;c.beforeCreate=d?[].concat(d,a):[a]}return{exports:t,options:c}}var l=c(a,i,u,!1,null,null,null),d=l.exports,f=function(){var t=this,n=t.$createElement,e=t._self._c||n;return e("a",[t._t("default")],2)},p=[],b={},_=c(b,f,p,!1,null,null,null),y=_.exports,m={name:"FButton",components:{ActionButton:d,LinkButton:y},props:{buttonType:{type:String,default:"primary"},buttonSize:{type:String,default:"medium"},isFullWidth:{type:Boolean,default:!1},actionType:{type:String,default:"button"},isIcon:{type:Boolean,default:!1},isLoading:{type:Boolean,default:!1}},computed:{buttonSizeClassname:function(){return"xsmall"===this.buttonSize?this.buttonSize.slice(0,2).toUpperCase()+this.buttonSize.slice(2):this.buttonSize.charAt(0).toUpperCase()+this.buttonSize.slice(1)},componentType:function(){return this.$attrs.href?"link-button":this.$attrs.to?"router-link":"action-button"},buttonActionType:function(){return this.$attrs.href||this.$attrs.to?null:this.actionType},getAriaLive:function(){return this.isLoading?"polite":"off"}}},h=m,g=e("4e4b");function v(t){this["$style"]=g["default"].locals||g["default"]}var S=c(h,o,r,!1,v,null,null);n["a"]=S.exports},"4e4b":function(t,n,e){"use strict";var o=e("9a8d"),r=e.n(o);e.d(n,"default",(function(){return r.a}))},"7e10":function(t,n,e){var o,r,i;(function(e,u){r=[],o=u,i="function"===typeof o?o.apply(n,r):o,void 0===i||(t.exports=i)})("undefined"!==typeof self&&self,(function(){function t(){var n=Object.getOwnPropertyDescriptor(document,"currentScript");if(!n&&"currentScript"in document&&document.currentScript)return document.currentScript;if(n&&n.get!==t&&document.currentScript)return document.currentScript;try{throw new Error}catch(p){var e,o,r,i=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,u=/@([^@]*):(\d+):(\d+)\s*$/gi,s=i.exec(p.stack)||u.exec(p.stack),a=s&&s[1]||!1,c=s&&s[2]||!1,l=document.location.href.replace(document.location.hash,""),d=document.getElementsByTagName("script");a===l&&(e=document.documentElement.outerHTML,o=new RegExp("(?:[^\\n]+?\\n){0,"+(c-2)+"}[^<]*<script>([\\d\\D]*?)<\\/script>[\\d\\D]*","i"),r=e.replace(o,"$1").trim());for(var f=0;f<d.length;f++){if("interactive"===d[f].readyState)return d[f];if(d[f].src===a)return d[f];if(a===l&&d[f].innerHTML&&d[f].innerHTML.trim()===r)return d[f]}return null}}return t}))},"9a8d":function(t,n,e){t.exports={"c-screen-sizer":"Button_c-screen-sizer_aacnl","c-spinner-wrapper":"Button_c-spinner-wrapper_16dYe","c-spinner":"Button_c-spinner_16ib0",spin:"Button_spin_1l7_1","o-btn":"Button_o-btn_1KX8u","o-btnLink":"Button_o-btnLink_MQkN7","o-btn-text":"Button_o-btn-text_3sVkf","o-btn-text--hidden":"Button_o-btn-text--hidden_6AbPr","o-btn--primary":"Button_o-btn--primary_NRuBe","o-btn--icon":"Button_o-btn--icon_1k-qM","o-btn--sizeLarge":"Button_o-btn--sizeLarge_3A8Ov","o-btn--loading":"Button_o-btn--loading_2up-7","o-btn--secondary":"Button_o-btn--secondary_1KBR1","o-btn--outline":"Button_o-btn--outline_3TR6n","o-btn--ghost":"Button_o-btn--ghost_1hnGu","o-btn--link":"Button_o-btn--link_2f-eF","o-btn--sizeMedium":"Button_o-btn--sizeMedium_2uSln","o-btn--sizeSmall":"Button_o-btn--sizeSmall_WNBZx","o-btn--sizeXSmall":"Button_o-btn--sizeXSmall_3KRtq","o-btn--fullWidth":"Button_o-btn--fullWidth_1xkfh","is-disabled":"Button_is-disabled_1zPQV",skeletonGradient:"Button_skeletonGradient_2l0Iq"}},b635:function(t,n,e){"use strict";(function(t){e.d(n,"b",(function(){return r}));var o=e("2a7d");function r(t){r.installed||(r.installed=!0,t.component("FButton",o["a"]))}var i={install:r},u=null;"undefined"!==typeof window?u=window.Vue:"undefined"!==typeof t&&(u=t.Vue),u&&u.use(i),n["a"]=o["a"]}).call(this,e("05e9"))},fa16:function(t,n,e){"use strict";if(e.r(n),"undefined"!==typeof window){var o=window.document.currentScript,r=e("7e10");o=r(),"currentScript"in document||Object.defineProperty(document,"currentScript",{get:r});var i=o&&o.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);i&&(e.p=i[1])}var u=e("b635");e.d(n,"install",(function(){return u["b"]}));n["default"]=u["a"]}})})); | ||
//# sourceMappingURL=f-button.umd.min.js.map |
{ | ||
"name": "@justeat/f-button", | ||
"description": "Fozzie Button – The generic button component", | ||
"version": "1.6.1", | ||
"version": "1.7.0", | ||
"main": "dist/f-button.umd.min.js", | ||
@@ -49,5 +49,8 @@ "files": [ | ||
"peerDependencies": { | ||
"@justeat/browserslist-config-fozzie": ">=1.1.1" | ||
"@justeat/browserslist-config-fozzie": ">=1.1.1", | ||
"vue": "2.x", | ||
"vue-router": ">=3.4.8" | ||
}, | ||
"devDependencies": { | ||
"@justeat/f-wdio-utils": "0.2.0", | ||
"@samhammer/vue-cli-plugin-stylelint": "2.0.1", | ||
@@ -58,5 +61,5 @@ "@vue/cli-plugin-babel": "4.4.6", | ||
"@vue/test-utils": "1.0.3", | ||
"@justeat/f-wdio-utils": "0.2.0", | ||
"node-sass-magic-importer": "5.3.2" | ||
"node-sass-magic-importer": "5.3.2", | ||
"vue-router": "^3.5.1" | ||
} | ||
} |
@@ -74,2 +74,3 @@ | ||
When `to` attribute is set, it uses Vue Router `router-link` component, this helps solve the issue with App router links reloading the page upon navigation. Note for it to work properly, it is required for the host project to have `vue-router` installed and set. | ||
@@ -82,10 +83,12 @@ ### Props | ||
| Prop | Type | Required | Default | Description | | ||
| :--- | :---: | :---: | :---: | :--- | | ||
| `actionType` | `String` | No | `button` | Sets the action button type.<br>Options: `button`, `submit`, `reset`. | | ||
| `buttonType` | `String` | No | `primary`| Sets the modifier theme for styling.<br>Options: `primary`, `secondary`, `outline`, `ghost`, `link`. | | ||
| `buttonSize` | `String` | No | `medium` | Sets the button size.<br>Options: `large`, `medium`, `small`, `xsmall`. | | ||
| `isFullWidth` | `Boolean` | No | `false` | Controls whether or not to apply `fullWidth` modifier class | | ||
| `isIcon` | `Boolean` | No | `false` | When true, changes the button style to be displayed as an Icon Button (Icon, with no text). | | ||
| `isLoading` | `Boolean` | No | `false` | When true, replaces the text with a loading spinner, and it prevents any further interaction with the button (e.g. `click`). | | ||
| Prop | Type | Required | Default | Description | | ||
| :--- | :---: | :---: | :---: | :--- | | ||
| `actionType` | `String` | No | `button` | Sets the action button type.<br>Options: `button`, `submit`, `reset`. | | ||
| `buttonType` | `String` | No | `primary`| Sets the modifier theme for styling.<br>Options: `primary`, `secondary`, `outline`, `ghost`, `link`. | | ||
| `buttonSize` | `String` | No | `medium` | Sets the button size.<br>Options: `large`, `medium`, `small`, `xsmall`. | | ||
| `isFullWidth` | `Boolean` | No | `false` | Controls whether or not to apply `fullWidth` modifier class | | ||
| `isIcon` | `Boolean` | No | `false` | When true, changes the button style to be displayed as an Icon Button (Icon, with no text). | | ||
| `isLoading` | `Boolean` | No | `false` | When true, replaces the text with a loading spinner, and it prevents any further interaction with the button (e.g. `click`). | | ||
| `href` | `String` | No | `null` | When set, generated markup is Anchor element e.g. <a> | | ||
| `to` | `String, Object` | No | `null` | When set, generated markup is Anchor element e.g. <a>. Additionally it allows to work with host App defined routes. | | ||
@@ -92,0 +95,0 @@ ### CSS Classes |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
209182
1188
130
3
8