mirror of
https://github.com/tabler/tabler.git
synced 2026-08-05 01:44:41 +04:00
Fix prettier silently skipping preview's built HTML (#2736)
This commit is contained in:
@@ -22,9 +22,13 @@ The basic implementation of Dropzone allows you to quickly enable drag-and-drop
|
||||
To initialize the Dropzone form, you need to create a new instance of the Dropzone class and pass the form element as an argument. Here’s how you can do it:
|
||||
|
||||
```html
|
||||
<script>{`document.addEventListener("DOMContentLoaded", function () {
|
||||
<script>
|
||||
{
|
||||
`document.addEventListener("DOMContentLoaded", function () {
|
||||
new Dropzone("#dropzone-default");
|
||||
});`}</script>
|
||||
});`;
|
||||
}
|
||||
</script>
|
||||
```
|
||||
|
||||
The Dropzone form will now be active and ready to accept file uploads. When a user drags and drops a file onto the form, the file will be uploaded to the server automatically.
|
||||
|
||||
@@ -36,7 +36,14 @@ Use an input mask in the fields where users have to enter their phone number, to
|
||||
To create an input mask, add the `data-mask` attribute to the input element:
|
||||
|
||||
```html
|
||||
<input type="text" name="input-mask" class="form-control" data-mask="(00) 0000-0000" placeholder="(00) 0000-0000" autocomplete="off" />
|
||||
<input
|
||||
type="text"
|
||||
name="input-mask"
|
||||
class="form-control"
|
||||
data-mask="(00) 0000-0000"
|
||||
placeholder="(00) 0000-0000"
|
||||
autocomplete="off"
|
||||
/>
|
||||
```
|
||||
|
||||
Look at the example below to see how the input mask works:
|
||||
|
||||
@@ -52,11 +52,10 @@ In SvelteKit, load `tabler.min.js` only on the client. `onMount` runs only in th
|
||||
|
||||
```html
|
||||
<script>
|
||||
import { onMount } from 'svelte'
|
||||
|
||||
import { onMount } from "svelte";
|
||||
onMount(() => {
|
||||
import('@tabler/core/dist/js/tabler.min.js')
|
||||
})
|
||||
import("@tabler/core/dist/js/tabler.min.js");
|
||||
});
|
||||
</script>
|
||||
```
|
||||
|
||||
@@ -68,14 +67,12 @@ Create a simple `src/routes/+layout.svelte` that loads global styles and Tabler
|
||||
|
||||
```html
|
||||
<script>
|
||||
import { onMount } from 'svelte'
|
||||
import '../app.css'
|
||||
|
||||
import { onMount } from "svelte";
|
||||
import "../app.css";
|
||||
onMount(() => {
|
||||
import('@tabler/core/dist/js/tabler.min.js')
|
||||
})
|
||||
import("@tabler/core/dist/js/tabler.min.js");
|
||||
});
|
||||
</script>
|
||||
|
||||
<slot />
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user