You've already forked AstralRinth
forked from didirus/AstralRinth
Skip Typescript compilation on packaging
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
import IconChat from 'virtual:icons/heroicons-outline/chat-alt-2'
|
||||
import { onMount } from 'svelte'
|
||||
|
||||
let headerElement
|
||||
let headerElement: HTMLElement
|
||||
|
||||
onMount(() => {
|
||||
let lastScrollTop: number
|
||||
|
||||
1
docs/global.d.ts
vendored
1
docs/global.d.ts
vendored
@@ -2,6 +2,7 @@
|
||||
|
||||
declare module '$assets/images/*'
|
||||
declare module '$locales/*'
|
||||
declare module 'insane'
|
||||
|
||||
declare module '*.svg' {
|
||||
export { SvelteComponentDev as default } from 'svelte/internal'
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
$page.url.pathname.replace('/', '') || 'index'
|
||||
}.md`
|
||||
|
||||
let api
|
||||
let api = { props: [], events: [], slots: [] }
|
||||
if ($page.url.pathname.includes('components')) {
|
||||
if (import.meta.env.DEV) {
|
||||
import(`../../src/components/${title}.svelte?raw&sveld`).then(
|
||||
|
||||
@@ -2,7 +2,7 @@ import { ComponentParser } from 'sveld'
|
||||
import * as svelte from 'svelte/compiler'
|
||||
import fs from 'fs/promises'
|
||||
import path from 'path'
|
||||
import { preprocess } from '../../src/config/svelte.config.js'
|
||||
import { preprocess } from '../../src/config/svelte.js'
|
||||
|
||||
export default function sveld() {
|
||||
return {
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
<a class="link" href="#issues"><IconIssues /> Issues</a>
|
||||
<a class="link" href="#source"><IconCode /> Source</a>
|
||||
<a class="link" href="#wiki"><IconWiki /> Wiki</a>
|
||||
<a class="link" href="#issues"><IconIssues /> Discord chat</a>
|
||||
<a class="link" href="#issues"><IconIssues /> Discord chat</a>
|
||||
<a class="link" href="#source"><IconCode /> Source link</a>
|
||||
</div>
|
||||
```
|
||||
|
||||
@@ -4,11 +4,11 @@
|
||||
<script lang="ts">
|
||||
import { Field, FileUpload } from 'omorphia'
|
||||
|
||||
let file: File
|
||||
let file: File
|
||||
</script>
|
||||
|
||||
<Field label="Upload image">
|
||||
<FileUpload accept="image/*" constrained bind:file />
|
||||
<FileUpload accept="image/*" constrained bind:file />
|
||||
</Field>
|
||||
|
||||
File name: {file?.name}
|
||||
@@ -20,11 +20,11 @@ File name: {file?.name}
|
||||
<script lang="ts">
|
||||
import { Field, FileUpload } from 'omorphia'
|
||||
|
||||
let files: File[] = []
|
||||
let files: File[] = []
|
||||
</script>
|
||||
|
||||
<Field label="Upload file">
|
||||
<FileUpload accept="*" multiple bind:files />
|
||||
<FileUpload accept="*" multiple bind:files />
|
||||
</Field>
|
||||
|
||||
Count: {files.length}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<script lang="ts">
|
||||
import { Modal, Button } from 'omorphia'
|
||||
import IconArrowRight from 'virtual:icons/heroicons-outline/arrow-right'
|
||||
import IconCheck from 'virtual:icons/heroicons-outline/check'
|
||||
import IconCheck from 'virtual:icons/heroicons-outline/check'
|
||||
</script>
|
||||
|
||||
<Modal title="Example modal" danger let:trigger>
|
||||
@@ -12,7 +12,7 @@
|
||||
<Button color="primary" slot="button"><IconArrowRight /> Continue</Button>
|
||||
</Modal>
|
||||
|
||||
<Modal let:trigger size='sm'>
|
||||
<Modal let:trigger size="sm">
|
||||
<Button on:click={trigger} slot="trigger">Confirm modal</Button>
|
||||
|
||||
Are you sure you want to delete this gallery image?
|
||||
|
||||
@@ -3,7 +3,11 @@
|
||||
import { ModalDeletion, Button } from 'omorphia'
|
||||
</script>
|
||||
|
||||
<ModalDeletion type="account" key="venashial" let:trigger on:deletion={() => console.log('Do something...')}>
|
||||
<ModalDeletion
|
||||
type="account"
|
||||
key="venashial"
|
||||
let:trigger
|
||||
on:deletion={() => console.log('Do something...')}>
|
||||
<Button slot="trigger" color="danger" on:click={trigger}>Delete account</Button>
|
||||
</ModalDeletion>
|
||||
```
|
||||
|
||||
@@ -9,7 +9,7 @@ To make use of the built-in icons, styles, and plugins in omorphia, you will nee
|
||||
Add the following parts to your `svelte.config.js` file:
|
||||
|
||||
```js
|
||||
import { preprocess, plugins } from 'omorphia/config/svelte.config'
|
||||
import { preprocess, plugins } from 'omorphia/config/svelte.js'
|
||||
|
||||
/** @type {import('@sveltejs/kit').Config} */
|
||||
const config = {
|
||||
@@ -32,5 +32,5 @@ Create a `postcss.config.cjs` file in the root of your project.
|
||||
Add the following line to that file:
|
||||
|
||||
```js
|
||||
module.exports = require('omorphia/config/postcss.config.cjs')
|
||||
module.exports = require('omorphia/config/postcss.cjs')
|
||||
```
|
||||
|
||||
@@ -23,14 +23,16 @@ The `markdown` parser is designed for bodies of markdown text and supports image
|
||||
#### An image \n\
|
||||
'
|
||||
</script>
|
||||
|
||||
<div class="card markdown">
|
||||
{@html markdown(source)}
|
||||
{@html markdown(
|
||||
` | Syntax | Description |
|
||||
{@html markdown(
|
||||
` | Syntax | Description |
|
||||
| ----------- | ----------- |
|
||||
| Header | Title |
|
||||
| Paragraph | Text |`)}
|
||||
{@html markdown('```js\nconsole.log("test")\n```')}
|
||||
| Paragraph | Text |`
|
||||
)}
|
||||
{@html markdown('```js\nconsole.log("test")\n```')}
|
||||
</div>
|
||||
````
|
||||
|
||||
|
||||
Reference in New Issue
Block a user