Skip to content
This repository was archived by the owner on Jan 9, 2022. It is now read-only.

Commit 410f61b

Browse files
committed
feat(docs): upgrade to [email protected]
1 parent 4255bc7 commit 410f61b

File tree

4 files changed

+106
-8
lines changed

4 files changed

+106
-8
lines changed

docs/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
"@mdi/js": "^5.9.55",
2020
"@vueuse/core": "^6.0.0",
2121
"balm-ui": "9.36.0",
22-
"gitart-vue-dialog": "^0.2.0-alpha.3",
22+
"gitart-vue-dialog": "0.2.0",
2323
"markdown-it-container": "^3.0.0",
2424
"prismjs": "^1.24.1",
2525
"sass": "^1.38.0"

docs/src/components/Examples/Introduction/GettingStartedExampleStyled.vue

-2
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,6 @@ export default {
4646

4747
<style lang="scss">
4848
.getting-started-example-styled {
49-
background: #fff;
50-
5149
&__content {
5250
padding: 20px;
5351
}

docs/src/docs/components/g-dialog.md

+101-1
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,10 @@ z-index of the component is 200. So be careful. Don't make z-index of the header
1919
| [height](#height) | `string` `number` | `'auto'` |
2020
| [max-width](#max-width) | `string` `number` | `'none'` |
2121
| [model-value](#model-value) | `boolean` | `false` |
22+
| [overlay-background](#overlay-background) | `boolean` `string` | `true` |
2223
| [persistent](#persistent) | `boolean` | `false` |
2324
| [scrollable](#scrollable) | `boolean` | `false` |
25+
| [transition](#transition) | `string` | `g-dialog-transition` |
2426
| [width](#width) | `string` `number` | `'auto'` |
2527

2628

@@ -32,6 +34,12 @@ z-index of the component is 200. So be careful. Don't make z-index of the header
3234
- **Details:** <br/>
3335
Sets background to the dialog content
3436

37+
- `true` - remains [default](#content-bg) backround,
38+
- `false` - removes background
39+
- `String` - sets some backround to the current dialog content
40+
41+
You can set default value for all dialogs by CSS var [--g-dialog-content-bg](#content-bg)
42+
3543
---
3644

3745
### `border-radius`
@@ -42,6 +50,12 @@ z-index of the component is 200. So be careful. Don't make z-index of the header
4250
- **Details:** <br/>
4351
Sets border-radius to the dialog content
4452

53+
- `true` - remains [default](#content-border-radius) border-radius,
54+
- `false` - removes border-radius
55+
- `String` - sets some border-radius to the current dialog content
56+
57+
You can set default value for all dialogs by CSS var [--g-dialog-content-border-radius](#content-border-radius)
58+
4559
---
4660

4761
### `content-class`
@@ -93,6 +107,21 @@ v-model props to activate and deactivate the dialog
93107

94108
---
95109

110+
### `overlay-background`
111+
- **Type:** `Boolean | String`
112+
113+
- **Default:** `true`
114+
115+
- **Details:** <br/>
116+
Sets dialog overlay background.
117+
- `true` - remains [default](#overlay-bg) backround,
118+
- `false` - removes background
119+
- `String` - sets some backround to the current dialog overlay
120+
121+
You can set default value for all dialogs by CSS var [--g-dialog-overlay-bg](#overlay-bg)
122+
123+
---
124+
96125
### `persistent`
97126
- **Type:** `Boolean`
98127

@@ -110,6 +139,44 @@ Makes clicking outside of the element will not deactivate the dialog
110139

111140
<!-- - **Details:** <br/> -->
112141

142+
---
143+
### `transition`
144+
- **Type:** `String`
145+
146+
- **Default:** `'g-dialog-transition'`
147+
148+
- **Details:** <br/>
149+
Sets the component custom transition name (leaving and entering the dialog). Here is example:
150+
151+
```scss
152+
// transition="custom-rotate-transition"
153+
.custom-rotate-transition {
154+
&-enter-active,
155+
&-leave-active {
156+
transition-timing-function: linear;
157+
transition-duration: 0.1s; // not higher than 200ms
158+
}
159+
160+
&-enter-from {
161+
transform: translate(0, 30px) rotate(12deg);
162+
opacity: 0;
163+
}
164+
165+
&-leave-to {
166+
transform: translate(0, 30px) rotate(4deg);
167+
opacity: 0;
168+
}
169+
}
170+
```
171+
172+
::: warning
173+
On leaving don't set `transition-duration` higher than `150ms`-`200ms` if you are using
174+
plugin method [addDialog](/docs/guide/plugin-usage#adddialog-data).
175+
176+
[removeDialog](/docs/guide/plugin-usage#removedialog-index) disables a dialog and deletes it after 150ms
177+
completely, so the custom transition may be truncated
178+
:::
179+
113180
---
114181
### `width`
115182
- **Type:** `String | Number`
@@ -125,7 +192,7 @@ Sets width for the dialog
125192

126193
| Name | Description |
127194
|:---|:---|
128-
| default | The default Vue slot
195+
| default | The default Vue slot |
129196

130197

131198
## Events
@@ -177,4 +244,37 @@ Or use CSS variables to do it globally. Put the vars into your global css file o
177244
```css
178245
--g-dialog-border-radius: 0;
179246
```
247+
---
248+
249+
### content-shadow
250+
- **Name:** `--g-dialog-content-shadow`
251+
252+
- **Default:** <br/>
253+
`0 11px 15px -7px rgb(0 0 0 / 20%),` <br/>
254+
`0 24px 38px 3px rgb(0 0 0 / 14%),` <br/>
255+
`0 9px 46px 8px rgb(0 0 0 / 12%)` <br/>
256+
257+
- **Details:**<br/>
258+
Sets default `box-shadow` for the dialog content
259+
260+
- **Usage:**
261+
262+
```css
263+
--g-dialog-content-shadow: 0 11px 15px -7px rgb(0 0 0 / 20%);
264+
```
265+
---
266+
267+
### overlay-bg
268+
- **Name:** `--g-dialog-overlay-bg`
269+
270+
- **Default:** `rgba(33, 33, 33, 0.46)`
271+
272+
- **Details:**<br/>
273+
Sets default `background` for the dialog overlay
274+
275+
- **Usage:**
276+
277+
```css
278+
--g-dialog-overlay-bg: rgba(143, 108, 249, 0.4);
279+
```
180280
---

docs/yarn.lock

+4-4
Original file line numberDiff line numberDiff line change
@@ -1407,10 +1407,10 @@ get-intrinsic@^1.0.2:
14071407
has "^1.0.3"
14081408
has-symbols "^1.0.1"
14091409

1410-
gitart-vue-dialog@^0.2.0-alpha.3:
1411-
version "0.2.0-alpha.3"
1412-
resolved "https://registry.yarnpkg.com/gitart-vue-dialog/-/gitart-vue-dialog-0.2.0-alpha.3.tgz#2e3372c327f7fd932ce4050a870ee22a59b64b7f"
1413-
integrity sha512-eRzWZc+7O52TkOXrx6r70CahOpfRa9mbVeV5Oq5j39GiZ9IeSwfEUlPIQ65L/lxQ+fTtZ0Xa433U0HyJNgQDew==
1410+
1411+
version "0.2.0"
1412+
resolved "https://registry.yarnpkg.com/gitart-vue-dialog/-/gitart-vue-dialog-0.2.0.tgz#1775f2fedb715587e9c00ca5b8ba4a55d94c9c18"
1413+
integrity sha512-F9D5VYESUa52xbDIz42GmWBbgruh86/GDmjBnrQb3zmLAH1osLbi/JfvCAvi4V39lBtRWbk1zc1XNRiC+5uB2Q==
14141414

14151415
glob-parent@^5.1.2, glob-parent@~5.1.2:
14161416
version "5.1.2"

0 commit comments

Comments
 (0)