Skip to content

Commit 99a0e42

Browse files
committed
Merge branch 'dev' into next
2 parents 2fae61f + 6a4cd4c commit 99a0e42

File tree

10 files changed

+48
-15
lines changed

10 files changed

+48
-15
lines changed

README.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -238,14 +238,15 @@ toggle modal by name.
238238
## **Props**
239239

240240
```js
241-
const CLASS_TYPES = [String, Object, Array]
242-
243241
{
244242
value: { type: Boolean, default: false },
245243
ssr: { type: Boolean, default: true },
246-
classes: { type: CLASS_TYPES, default: '' },
247-
overlayClass: { type: CLASS_TYPES, default: '' },
248-
contentClass: { type: CLASS_TYPES, default: '' },
244+
classes: { type: [String, Object, Array], default: '' },
245+
overlayClass: { type: [String, Object, Array], default: '' },
246+
contentClass: { type: [String, Object, Array], default: '' },
247+
styles: { type: [String, Object, Array], default: '' },
248+
overlayStyle: { type: [String, Object, Array], default: '' },
249+
contentStyle: { type: [String, Object, Array], default: '' },
249250
lockScroll: { type: Boolean, default: true },
250251
hideOverlay: { type: Boolean, default: false },
251252
clickToClose: { type: Boolean, default: true },

dist/VueFinalModal.esm.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/VueFinalModal.esm.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/VueFinalModal.umd.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/VueFinalModal.umd.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/content/en/examples/recommended-use.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ title: Recommended use
33
description: 'Vue Final Modal is a renderless, stackable, detachable and lightweight modal component.'
44
position: 3
55
category: Examples
6+
version: 0.17
67
---
78

89

@@ -44,7 +45,8 @@ You can create a `higher-order component` easily and can customize `template`, `
4445
4546
<script>
4647
export default {
47-
name: 'VModal'
48+
name: 'VModal',
49+
inheritAttrs: false
4850
}
4951
</script>
5052

docs/content/en/index.md

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: Introduction
33
description: 'Vue Final Modal is a renderless, stackable, detachable and lightweight modal component.'
44
position: 0
55
category: Getting Start
6-
version: 0.14
6+
version: 0.17
77
features:
88
- Support Vue 3 and Vue 2
99
- Tailwind CSS friendly
@@ -276,11 +276,35 @@ Custom class names for the modal content element.
276276

277277
### `overlayClass`
278278

279-
- Type: `String`
279+
- Type: `[String, Object, Array]`
280280
- Default: `''`
281281

282282
Custom class names for the modal overlay element.
283283

284+
### `styles`
285+
<badge>v0.17+</badge>
286+
287+
- Type: `[String, Object, Array]`
288+
- Default: `''`
289+
290+
Style that will be applied to the modal container element.
291+
292+
### `contentStyle`
293+
<badge>v0.17+</badge>
294+
295+
- Type: `[String, Object, Array]`
296+
- Default: `''`
297+
298+
Style that will be applied to the modal content element.
299+
300+
### `overlayStyle`
301+
<badge>v0.17+</badge>
302+
303+
- Type: `[String, Object, Array]`
304+
- Default: `''`
305+
306+
Style that will be applied to the modal overlay element.
307+
284308
### `transition`
285309

286310
- Type: `String`

example/src/components/hoc/VModal.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@
2222

2323
<script>
2424
export default {
25-
name: 'VModal'
25+
name: 'VModal',
26+
inheritAttrs: false
2627
}
2728
</script>
2829

lib/VueFinalModal.vue

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
v-show="!hideOverlay && visibility.overlay"
2222
class="vfm__overlay vfm--overlay vfm--absolute vfm--inset"
2323
:class="overlayClass"
24-
:aria-expanded="visibility.overlay.toString()"
24+
:style="overlayStyle"
2525
></div>
2626
</transition>
2727
<transition
@@ -36,6 +36,7 @@
3636
ref="vfmContainer"
3737
class="vfm__container vfm--absolute vfm--inset vfm--outline-none"
3838
:class="[classes, { 'vfm--cursor-pointer': clickToClose }]"
39+
:style="styles"
3940
:aria-expanded="visibility.modal.toString()"
4041
role="dialog"
4142
aria-modal="true"
@@ -45,6 +46,7 @@
4546
ref="vfmContent"
4647
class="vfm__content vfm--cursor-auto"
4748
:class="[contentClass, { 'vfm--prevent-auto': preventClick }]"
49+
:style="contentStyle"
4850
@click.stop
4951
>
5052
<slot />
@@ -84,6 +86,9 @@ export default {
8486
classes: { type: [String, Object, Array], default: '' },
8587
overlayClass: { type: [String, Object, Array], default: '' },
8688
contentClass: { type: [String, Object, Array], default: '' },
89+
styles: { type: [String, Object, Array], default: '' },
90+
overlayStyle: { type: [String, Object, Array], default: '' },
91+
contentStyle: { type: [String, Object, Array], default: '' },
8792
lockScroll: { type: Boolean, default: true },
8893
hideOverlay: { type: Boolean, default: false },
8994
clickToClose: { type: Boolean, default: true },

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vue-final-modal",
3-
"version": "1.3.0",
3+
"version": "1.4.0",
44
"description": "Vue Final Modal is a renderless, stackable, detachable and lightweight modal component.",
55
"private": false,
66
"main": "dist/VueFinalModal.umd.js",

0 commit comments

Comments
 (0)