@el3um4s/svelte-titlebar
TypeScript icon, indicating that this package has built-in type declarations

0.1.0 • Public • Published

SVELTE-TITLEBAR

A Titlebar component for Svelte Projects

Live demo: el3um4s.github.io/svelte-titlebar/ NPM: @el3um4s/svelte-titlebar

Install and use the package

To use the package in a project:

npm i -D @el3um4s/svelte-titlebar

and then in a file:

<script>
	import { TitleBar } from '@el3um4s/svelte-titlebar';
</script>

<TitleBar
	{title}
	{isMaximized}
	on:clickMinimize={() => log('minimize')}
	on:clickUnmaximize={unmaximize}
	on:clickMaximize={maximize}
	on:clickClose={() => log('close')}
	class={theme}
	--background-color={backgroundColor}
	--text-color={textColor}
/>

API - Props

Prop Name Type Default value
title string Title
isMaximized boolean false

API - Forwarded events

  • on:clickMinimize
  • on:clickUnmaximize
  • on:clickMaximize
  • on:clickClose

Screenshot

test-default

test-light

test-themes-colors

Package Sidebar

Install

npm i @el3um4s/svelte-titlebar

Weekly Downloads

1

Version

0.1.0

License

MIT

Unpacked Size

13.6 kB

Total Files

14

Last publish

Collaborators

  • el3um4s