Skip to content

Commit e1ef4a9

Browse files
committed
hot-fix: fix en docs.
1 parent 6cfb2ec commit e1ef4a9

File tree

9 files changed

+55
-54
lines changed

9 files changed

+55
-54
lines changed

docs/fields/form-fields.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ Password entry field. It has the ability to switch the visibility mode.
134134
```
135135
<FormField type="password" label="Password" name="password" />
136136

137-
##Checkbox
137+
## Checkbox
138138

139139
Elements of type checkbox are displayed as checked checkboxes by default.
140140
(marked) upon activation, as you can see on the official government paper form.

docs/fields/new-fields.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -38,21 +38,21 @@ In cases with countries, the widget will look like this:
3838

3939
```vue
4040
<template>
41-
<div>
42-
<form-field
43-
v-bind = "$attrs"
44-
type="select"
45-
:options = "countryOptions"
46-
/>
47-
</div>
41+
<div>
42+
<form-field
43+
v-bind = "$attrs"
44+
type="select"
45+
:options = "countryOptions"
46+
/>
47+
</div>
4848
</template>
4949
<script setup>
5050
import {FormField} from "jenesius-vue-form";
5151
5252
const countryOptions = [
53-
{ label: 'Canada', value: 'ca' },
54-
{ label: 'Australia', value: 'au' },
55-
// other
53+
{ label: 'Canada', value: 'ca' },
54+
{ label: 'Australia', value: 'au' },
55+
// other
5656
]
5757
</script>
5858
```
@@ -71,9 +71,9 @@ If you set the field via **config** and then use **formField** then the followin
7171

7272
```ts
7373
defineProps<{
74-
name:string
75-
modelValue: any
76-
...
74+
name:string
75+
modelValue: any
76+
...
7777
}>()
7878
```
7979

docs/guide/configuration.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,13 @@ config(params)
99
The Params object has the following type:
1010
```ts
1111
interface IConfigurationParams {
12-
inputTypes: {
13-
[name: string]: any
14-
},
15-
requiredMessage:string
16-
typeNotCaseSensitive: boolean
17-
debug: boolean
18-
defaultType: string
12+
inputTypes: {
13+
[name: string]: any
14+
},
15+
requiredMessage:string
16+
typeNotCaseSensitive: boolean
17+
debug: boolean
18+
defaultType: string
1919
}
2020
```
2121

docs/guide/form.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ import Form from "./Form";
1212

1313
const form = new Form()
1414
```
15-
Now you can add **FormField** to the page and they will automatically interact with **form**. Familiarize yourself
16-
with them you can HERE XXXXXXX.
15+
Now you can add **FormField** to the page, and they will automatically interact with **form**. Familiarize yourself
16+
with them you can [here](./../fields/form-fields.md).
1717

1818
### Options
1919

@@ -25,7 +25,8 @@ const form = new Form(params)
2525

2626
#### params <Badge type = "tip">Optional</Badge>
2727
An object with the following properties:
28-
:::info_
28+
29+
::: info _
2930

3031
#### name <Badge type = "warning">Variable</Badge>
3132
The name of the entity (field) that will be used if this form will act as a child and will be signed
@@ -36,7 +37,7 @@ null.
3637

3738
#### parent <Badge type = "info">Optional</Badge>
3839
It takes the following values: `Form` or `null`, `false`. If another Form was passed, then signing will occur
39-
on it, and not the automatic search for the parent form. Otherwise (null, false) this form will not produce
40+
on it, and not the automatic search for the parent form. Otherwise, (null, false) this form will not produce
4041
search for an ancestor.
4142

4243
#### provide <Badge type = "info">Optional</Badge>

docs/guide/getting-started.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ import WidgetExampleValues from '../components/widget-example-values.vue'
44

55
# Let's Start Using
66

7-
Creating a web application using Vue + JenesiusVueForm is an elegant and simple solution: a concise way to describe
8-
fields allows you to simplify the development of components, the large functionality of the library allows you to write multifunctional logic,
9-
and Vue's reactivity keeps our interface simple.
7+
Creating a web application using **Vue** + **JenesiusVueForm** is an elegant and simple solution: a concise way to describe
8+
fields allows you to simplify the development of components, the large functionality of the library allows you to write
9+
multifunctional logic and Vue's reactivity keeps our interface simple.
1010

1111
## Installation
1212
Install *jenesius-vue-form* as a dependency using any manager
@@ -34,9 +34,10 @@ by this library.
3434

3535
```vue{2,3}
3636
<template>
37-
<input-field name="username" label="Username"/>
38-
<input-field name="email" label="Email"/>
37+
<input-field name="username" label="Username"/>
38+
<input-field name="email" label="Email"/>
3939
</template>
40+
4041
<script setup>
4142
import {InputField, Form} from "jenesius-vue-form";
4243

docs/guide/peculiarities.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ Next, we will connect this component to our project
4747
```vue{4}
4848
// app.vue
4949
<template>
50-
<input-address name="address"/>
51-
<form-field name="address.city" label="Short City"/>
50+
<input-address name="address"/>
51+
<form-field name="address.city" label="Short City"/>
5252
</template>
5353
<script setup>
5454
import {FormField, Form} from "jenesius-vue-form";

docs/guide/reactivity.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@ const state = useFormState(form); // { changed, disabled }
7474
The reactive state has the following interface:
7575
```ts
7676
interface FormReactiveState {
77-
changed: boolean,
78-
disabled: boolean
79-
wait: boolean
77+
changed: boolean,
78+
disabled: boolean
79+
wait: boolean
8080
}
8181
```

docs/guide/validation.md

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@ child elements, and so on deeper.
77

88
```vue{7-9}
99
<template>
10-
<form-field name="age" :validation="ageValidation"/>
10+
<form-field name="age" :validation="ageValidation"/>
1111
</template>
1212
<script setup>
1313
import {Form, FormField} from "jenesius-vue-form";
1414
1515
function ageValidation(x) {
16-
return x > 17 || 'So small'
16+
return x > 17 || 'So small'
1717
}
1818
1919
form.setValues({ age: 17 });
@@ -30,7 +30,7 @@ For field validation, FormField takes one required parameter:
3030
It has the following type:
3131
```ts
3232
interface FormFieldProps {
33-
validation: FormFieldValidationCallback[] | FormFieldValidationCallback // [!code focus]
33+
validation: FormFieldValidationCallback[] | FormFieldValidationCallback // [!code focus]
3434
}
3535
```
3636
As you can see from the specification, the field can accept both a single function and an array of functions. The function type is described below:
@@ -47,14 +47,14 @@ type FormFieldValidationCallback = (value: any) => true | string | boolean
4747
### Size limit
4848
```vue
4949
<template>
50-
<form-field name="token" :validation="validation"/>
50+
<form-field name="token" :validation="validation"/>
5151
</template>
5252
<script setup>
5353
import {FormField, Form} from "jenesius-vue-form";
5454

5555
const validation = [
56-
x => x.length > 5 || "That's too short. The minimum length is 5.",
57-
x => x.length < 25 || "Value length must be less than 25."
56+
x => x.length > 5 || "That's too short. The minimum length is 5.",
57+
x => x.length < 25 || "Value length must be less than 25."
5858
]
5959
</script>
6060
```
@@ -69,22 +69,21 @@ In this example, there are two rules:
6969

7070
```vue{3}
7171
<template>
72-
<form-field type="switch" name="isAdmin"/>
73-
<form-field name="login" :validation="validation"/>
72+
<form-field type="switch" name="isAdmin"/>
73+
<form-field name="login" :validation="validation"/>
7474
</template>
7575
<script setup>
7676
import {FormField, Form, ComputedValue} from "jenesius-vue-form";
7777
7878
const form = new Form();
7979
const isAdmin = ComputedValue(form, "isAdmin"); // For reactive communication
8080
const validation = [
81-
login => {
82-
if (isAdmin.value && !login.startsWith('$'))
83-
return 'Administrator name must start with $';
84-
if (!isAdmin.value && login.length < 5)
85-
return 'Username must be at least 5 characters long.'
86-
87-
return true;
81+
login => {
82+
if (isAdmin.value && !login.startsWith('$'))
83+
return 'Administrator name must start with $';
84+
if (!isAdmin.value && login.length < 5)
85+
return 'Username must be at least 5 characters long.'
86+
return true;
8887
}
8988
]
9089
</script>

docs/guide/working-with-values.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ The values when will be set for the form.
2020
#### options <Badge type="info">Optional</Badge>
2121
An optional parameter, an object with the following properties:
2222

23-
:::info_
23+
::: info _
2424
##### changed <Badge type="info">Optional</Badge>
2525
Boolean value whether the given values are changes. If *true* then values will be projected onto changes.
2626

@@ -65,9 +65,9 @@ form.values // { name: "Jack" }
6565
#### Using target and clean together
6666
```ts
6767
form.setValues({
68-
name: "Jack",
69-
address: {
70-
city: "Emerald City"
68+
name: "Jack",
69+
address: {
70+
city: "Emerald City"
7171
}
7272
})
7373

0 commit comments

Comments
 (0)