Skip to content

Commit

Permalink
Changes for Standardize props, events, and slots carbon-design-system…
Browse files Browse the repository at this point in the history
  • Loading branch information
Samuel Janda committed Mar 8, 2024
1 parent 80f02d6 commit 87f8aa6
Showing 1 changed file with 12 additions and 13 deletions.
25 changes: 12 additions & 13 deletions src/TextInput/PasswordInput.svelte
Original file line number Diff line number Diff line change
@@ -1,16 +1,25 @@
<script>
/** Specify the input value */
export let value = "";
import { getContext } from "svelte";
import WarningFilled from "../icons/WarningFilled.svelte";
import WarningAltFilled from "../icons/WarningAltFilled.svelte";
import View from "../icons/View.svelte";
import ViewOff from "../icons/ViewOff.svelte";
/** Obtain a reference to the input HTML element */
export let ref = null;
/** Specify the input value */
export let value = "";
/**
* Set the size of the input
* @type {"sm" | "md" | "lg"}
*/
export let size = "md";
/** Set an id for the input element */
export let id = "ccs-" + Math.random().toString(36);
/** Specify the placeholder text */
export let placeholder = "";
Expand Down Expand Up @@ -70,9 +79,6 @@
/** Specify the warning state text */
export let warnText = "";
/** Set an id for the input element */
export let id = "ccs-" + Math.random().toString(36);
/**
* Specify a name attribute for the input
* @type {string}
Expand All @@ -94,13 +100,6 @@
*/
export let inputAttributes = {};
import { getContext } from "svelte";
import WarningFilled from "../icons/WarningFilled.svelte";
import WarningAltFilled from "../icons/WarningAltFilled.svelte";
import View from "../icons/View.svelte";
import ViewOff from "../icons/ViewOff.svelte";
import Tooltip from "../Tooltip/Tooltip.svelte";
const ctx = getContext("Form");
$: isFluid = !!ctx && ctx.isFluid;
Expand Down Expand Up @@ -289,4 +288,4 @@
<div class:bx--form-requirement="{true}" id="{warnId}">{warnText}</div>
{/if}
</div>
</div>
</div>

0 comments on commit 87f8aa6

Please sign in to comment.