mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-14 18:01:06 +00:00
test: delete old test files
This commit is contained in:
parent
d4ca8b5c97
commit
9b29aa091a
5 changed files with 0 additions and 109 deletions
|
@ -1,26 +0,0 @@
|
|||
<script lang="ts">
|
||||
import {
|
||||
ComposedModal,
|
||||
ModalHeader,
|
||||
ModalBody,
|
||||
ModalFooter,
|
||||
Checkbox,
|
||||
} from "carbon-components-svelte";
|
||||
|
||||
let checked = false;
|
||||
</script>
|
||||
|
||||
<ComposedModal open on:close on:click:button--primary>
|
||||
<ModalHeader title="Confirm changes" />
|
||||
<ModalBody hasForm>
|
||||
<Checkbox labelText="I have reviewed the changes" bind:checked />
|
||||
</ModalBody>
|
||||
<ModalFooter
|
||||
primaryButtonText="Proceed"
|
||||
primaryButtonDisabled={!checked}
|
||||
secondaryButtons={[{ text: "Cancel" }, { text: "Duplicate" }]}
|
||||
on:click:button--secondary={({ detail }) => {
|
||||
console.log(detail);
|
||||
}}
|
||||
/>
|
||||
</ComposedModal>
|
|
@ -1,21 +0,0 @@
|
|||
<script lang="ts">
|
||||
import { Button, Modal } from "carbon-components-svelte";
|
||||
|
||||
let open = false;
|
||||
</script>
|
||||
|
||||
<Button kind="danger" on:click={() => (open = true)}>Delete all</Button>
|
||||
|
||||
<Modal
|
||||
danger
|
||||
bind:open
|
||||
modalHeading="Delete all instances"
|
||||
primaryButtonText="Delete"
|
||||
secondaryButtonText="Cancel"
|
||||
on:click:button--secondary={() => (open = false)}
|
||||
on:open
|
||||
on:close
|
||||
on:submit
|
||||
>
|
||||
<p>This is a permanent action and cannot be undone.</p>
|
||||
</Modal>
|
|
@ -1,14 +0,0 @@
|
|||
<script lang="ts">
|
||||
import { Button, Modal } from "carbon-components-svelte";
|
||||
|
||||
let open = false;
|
||||
</script>
|
||||
|
||||
<Button kind="tertiary" on:click={() => (open = true)}>Learn more</Button>
|
||||
|
||||
<Modal passiveModal bind:open modalHeading="IBM Cloudant" on:open on:close>
|
||||
<p>
|
||||
IBM Cloudant is a distributed, secure database with global availability and
|
||||
zero vendor lock-in used to build web and mobile apps at scale.
|
||||
</p>
|
||||
</Modal>
|
|
@ -1,24 +0,0 @@
|
|||
<script lang="ts">
|
||||
import { DataTable } from "carbon-components-svelte";
|
||||
|
||||
const headers = [
|
||||
{ key: "name", value: "Name" },
|
||||
{ key: "port", value: "Port" },
|
||||
{ key: "rule", value: "Rule" },
|
||||
] as const;
|
||||
|
||||
const rows = [
|
||||
{ id: "a", name: "Load Balancer 3", port: 3000, rule: "Round robin" },
|
||||
{ id: "b", name: "Load Balancer 1", port: 443, rule: "Round robin" },
|
||||
{ id: "c", name: "Load Balancer 2", port: 80, rule: "DNS delegation" },
|
||||
{ id: "d", name: "Load Balancer 6", port: 3000, rule: "Round robin" },
|
||||
{ id: "e", name: "Load Balancer 4", port: 443, rule: "Round robin" },
|
||||
{ id: "f", name: "Load Balancer 5", port: 80, rule: "DNS delegation" },
|
||||
];
|
||||
|
||||
let selectedRowIds = [rows[1].id];
|
||||
|
||||
$: console.log("selectedRowIds", selectedRowIds);
|
||||
</script>
|
||||
|
||||
<DataTable radio bind:selectedRowIds {headers} {rows} />
|
|
@ -1,24 +0,0 @@
|
|||
<script lang="ts">
|
||||
import { DataTable } from "carbon-components-svelte";
|
||||
import type { ComponentProps } from "svelte";
|
||||
const headers = [
|
||||
{ key: "name", value: "Name" },
|
||||
{ key: "port", value: "Port" },
|
||||
{ key: "rule", value: "Rule" },
|
||||
] as const;
|
||||
|
||||
const rows = [
|
||||
{ id: "a", name: "Load Balancer 3", port: 3000, rule: "Round robin" },
|
||||
{ id: "b", name: "Load Balancer 1", port: 443, rule: "Round robin" },
|
||||
{ id: "c", name: "Load Balancer 2", port: 80, rule: "DNS delegation" },
|
||||
{ id: "d", name: "Load Balancer 6", port: 3000, rule: "Round robin" },
|
||||
{ id: "e", name: "Load Balancer 4", port: 443, rule: "Round robin" },
|
||||
{ id: "f", name: "Load Balancer 5", port: 80, rule: "DNS delegation" },
|
||||
];
|
||||
|
||||
let selectedRowIds: ComponentProps<DataTable>["selectedRowIds"] = [];
|
||||
|
||||
$: console.log("selectedRowIds", selectedRowIds);
|
||||
</script>
|
||||
|
||||
<DataTable selectable bind:selectedRowIds {headers} {rows} />
|
Loading…
Add table
Add a link
Reference in a new issue