@molecule/app-address-display-svelte
Feature · address-display · App (browser) · v1.1.3 · Apache-2.0
Formatted multi-line address card with edit/delete actions
npm install @molecule/app-address-display-svelteHow it works
@molecule/app-address-display-svelte is a ready-made address-display feature for the app (browser) side. It composes the core interfaces it needs, so it works with whichever providers your app has bonded.
<script lang="ts">
import { AddressDisplay } from '@molecule/app-address-display-svelte'
</script>
<AddressDisplay
name="Jane Smith"
address={{
line1: '123 Main St',
city: 'Springfield',
state: 'IL',
postalCode: '62701',
country: 'US',
}}
phone="+1 555-867-5309"
/>Works with: @molecule/app-svelte, @molecule/app-ui, @molecule/app-ui-svelte
Reference
Svelte formatted address display — the Svelte counterpart of
@molecule/app-address-display-react, with the same props and the same
DOM for the same input.
Exports AddressDisplay — formatted multi-line (or inline) address with
name, phone, leading icon, and action slots. Also exports the Address
type.
Auto-generated, AI-first package reference for the molecule.dev ecosystem. It is written to be read by coding agents as much as by people, and is generated from this package's source — edit
src/index.tsJSDoc, not this file.
Quick Start
<script lang="ts">
import { AddressDisplay } from '@molecule/app-address-display-svelte'
</script>
<AddressDisplay
name="Jane Smith"
address={{
line1: '123 Main St',
city: 'Springfield',
state: 'IL',
postalCode: '62701',
country: 'US',
}}
phone="+1 555-867-5309"
/>
Type
feature
Installation
npm install @molecule/app-address-display-svelte @molecule/app-svelte @molecule/app-ui @molecule/app-ui-svelte svelte
API
Interfaces
Address
Structured postal address with optional individual fields.
interface Address {
/** First line — street + number. */
line1?: string
/** Second line — apartment, suite, unit. */
line2?: string
/** City. */
city?: string
/** State / province / region. */
state?: string
/** ZIP / postal code. */
postalCode?: string
/** Country. */
country?: string
}
AddressDisplayProps
Props for AddressDisplay.
interface AddressDisplayProps {
/** Address fields. */
address: Address
/** Optional name / label preceding the address. */
name?: NodeProp
/** Optional phone number rendered under the address. */
phone?: string
/** Optional `<Icon>` / avatar leading slot. */
leading?: NodeProp
/** Optional right-side actions. */
actions?: NodeProp
/** Format as a single line instead of multi-line. */
inline?: boolean
/** Extra classes. */
className?: string
}
Constants
AddressDisplay
const AddressDisplay: LegacyComponentType
Injection Notes
Requirements
Peer dependencies:
@molecule/app-svelte^3.13.0 || ^4.0.0@molecule/app-ui^1.0.1@molecule/app-ui-svelte^1.1.0svelte^5.0.0
Runtime Dependencies
-
@molecule/app-svelte -
@molecule/app-ui -
@molecule/app-ui-svelte -
svelte -
Requires a bonded ClassMap — rendering throws otherwise. No i18n or router dependency.
-
The name, leading and actions are node-valued props: pass a snippet or plain text.