Skip to content

Commit

Permalink
chore(release): set package.json to 3.0.3 [skip ci]
Browse files Browse the repository at this point in the history
## [3.0.3](v3.0.2...v3.0.3) (2022-04-18)

### Bug Fixes

* added aria attributes ([50a52a0](50a52a0))
* added keyCode for keydown event ([084ec52](084ec52))
* added prop for close button label ([cd8a0c8](cd8a0c8))
  • Loading branch information
semantic-release-bot committed Apr 18, 2022
1 parent a17a1cb commit af3974f
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 13 deletions.
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
## [3.0.3](https://github.com/kouts/vue-modal/compare/v3.0.2...v3.0.3) (2022-04-18)


### Bug Fixes

* added aria attributes ([50a52a0](https://github.com/kouts/vue-modal/commit/50a52a0146082502eb88d534ab2ee46ac2b889f8))
* added keyCode for keydown event ([084ec52](https://github.com/kouts/vue-modal/commit/084ec525fbb0a437412c00df7868b3e8cbf90c65))
* added prop for close button label ([cd8a0c8](https://github.com/kouts/vue-modal/commit/cd8a0c802df7e219504fbbeeb923d7ece045d949))

## [3.0.2](https://github.com/kouts/vue-modal/compare/v3.0.1...v3.0.2) (2022-01-08)


Expand Down
38 changes: 26 additions & 12 deletions dist/vue-modal.es.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import { openBlock, createBlock, Teleport, createVNode, Transition, withCtx, withDirectives, createElementVNode, normalizeClass, normalizeStyle, vShow, renderSlot, toDisplayString, createElementBlock, withModifiers, createCommentVNode } from "vue";
var Modal_vue_vue_type_style_index_0_lang = "";
var _export_sfc = (sfc, props) => {
const target = sfc.__vccOpts || sfc;
for (const [key, val] of props) {
sfc[key] = val;
target[key] = val;
}
return sfc;
return target;
};
const TYPE_CSS = {
type: [String, Object, Array],
Expand Down Expand Up @@ -46,6 +47,10 @@ const _sfc_main = {
modelValue: {
type: Boolean,
default: false
},
closeLabel: {
type: String,
default: "Close"
}
},
emits: ["before-open", "opening", "after-open", "before-close", "closing", "after-close", "update:modelValue"],
Expand Down Expand Up @@ -93,10 +98,10 @@ const _sfc_main = {
}
},
keydown(e) {
if (e.which === 27) {
if (e.which === 27 || e.keyCode === 27) {
this.close();
}
if (e.which === 9) {
if (e.which === 9 || e.keyCode === 9) {
const all = [].slice.call(this.$refs["vm-wrapper"].querySelectorAll(FOCUSABLE_ELEMENTS)).filter(function(el) {
return !!(el.offsetWidth || el.offsetHeight || el.getClientRects().length);
});
Expand Down Expand Up @@ -188,11 +193,12 @@ const _sfc_main = {
}
};
const _hoisted_1 = ["data-vm-backdrop-id"];
const _hoisted_2 = ["data-vm-wrapper-id", "aria-label"];
const _hoisted_2 = ["data-vm-wrapper-id", "aria-label", "aria-describedby", "aria-labelledby"];
const _hoisted_3 = ["data-vm-id"];
const _hoisted_4 = { class: "vm-titlebar" };
const _hoisted_5 = { class: "vm-title" };
const _hoisted_6 = { class: "vm-content" };
const _hoisted_5 = ["id"];
const _hoisted_6 = ["aria-label"];
const _hoisted_7 = ["id"];
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
return $data.mount ? (openBlock(), createBlock(Teleport, {
key: 0,
Expand Down Expand Up @@ -235,6 +241,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
role: "dialog",
"aria-label": $props.title,
"aria-modal": "true",
"aria-describedby": `${$data.id}-content`,
"aria-labelledby": `${$data.id}-title`,
onClick: _cache[1] || (_cache[1] = ($event) => $options.clickOutside($event)),
onKeydown: _cache[2] || (_cache[2] = ($event) => $options.keydown($event))
}, [
Expand All @@ -246,20 +254,26 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
}, [
renderSlot(_ctx.$slots, "titlebar", {}, () => [
createElementVNode("div", _hoisted_4, [
createElementVNode("h3", _hoisted_5, toDisplayString($props.title), 1),
createElementVNode("h3", {
id: `${$data.id}-title`,
class: "vm-title"
}, toDisplayString($props.title), 9, _hoisted_5),
$props.enableClose ? (openBlock(), createElementBlock("button", {
key: 0,
type: "button",
class: "vm-btn-close",
"aria-label": "Close",
"aria-label": $props.closeLabel,
onClick: _cache[0] || (_cache[0] = withModifiers((...args) => $options.close && $options.close(...args), ["prevent"]))
})) : createCommentVNode("", true)
}, null, 8, _hoisted_6)) : createCommentVNode("", true)
])
]),
renderSlot(_ctx.$slots, "content", {}, () => [
createElementVNode("div", _hoisted_6, [
createElementVNode("div", {
id: `${$data.id}-content`,
class: "vm-content"
}, [
renderSlot(_ctx.$slots, "default")
])
], 8, _hoisted_7)
])
], 14, _hoisted_3)
], 46, _hoisted_2), [
Expand Down
2 changes: 1 addition & 1 deletion dist/vue-modal.umd.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit af3974f

Please sign in to comment.