2.1.3 • Published 8 months ago

@open-xamu-co/ui-nuxt v2.1.3

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

Xamu UI, Nuxt Module

npm (scoped) CircleCI

npm i @open-xamu-co/ui-nuxt
# or with yarn
yarn add @open-xamu-co/ui-nuxt

Features

  • I18n support
  • Image optimization with nuxt/image

Usage

Add to modules in nuxt.config.ts:

// nuxt.config.ts, basic setup

export default defineNuxtConfig({
	modules: ["@open-xamu-co/ui-nuxt"],
});

Settings

// nuxt.config.ts, example configuration

export default defineNuxtConfig({
	modules: ["@open-xamu-co/ui-nuxt"],
	xamu: {
		lang: "es",
		country: "co",
	},
});
NameTypeTypeDescription
webComponentsbooleanfalseUse web components
globalComponentsboolean | tComponent[]trueRegister all or specific components globally. If true, all components will be registered globally. If an array is provided, only the components specified in the array will be registered globally.
componentPrefixstring"xamu"Components prefix. The default value is "xamu".
routerComponentComponentType | stringNuxtLink component from "nuxt"Router component. If a router is used, this component is required for buttons to work.
imageComponentComponentType | stringNuxtImg component from "nuxt/image"Image component. This is an optional image optimization component.
imageHostsstring[][]Hosts that contain images. Any URLs within these hosts will be treated as images.
lang"kr" | "pt" | "nl" | "hr" | "fa" | "de" | "es" | "en" | "fr" | "ja" | "it" | "cn" | "tr""en"The locale language code. The default value is en (English).
localetPluginLocale{} en locale from "@open-xamu-co/ui-common-helpers/en"Global locale values. You can implement your own or use the ones provided by @open-xamu-co/ui-common-helpers/locale. The default value is en (English).
mediaQueryPixels{ laptop?: number; tablet?: number; mobile?: number; }{ laptop: 1080; tablet: 768; mobile: 576; }Object containing the media query limits (in pixels) for laptop, tablet, and mobile devices.
swal{ overrides?: SweetAlertOptions; preventOverrides?: SweetAlertOptions; loaderOverrides?: SweetAlertOptions; }{} Swal defaults from "@open-xamu-co/ui-common-helpers/swal"Object containing the overrides for the swal library.
countrystringundefinedISO 2 code for the default country. When a country is provided, forms will omit the country field.
disableAutoAnimatebooleanfalseA boolean value indicating whether to disable automatic animations.
fontAwesomeProbooleanfalseA boolean value indicating whether to use the Pro version of Font Awesome (regular and light styles).
firstnumber10The default pagination limit.

Used types can be imported from @open-xamu-co/ui-common-types or @open-xamu-co/ui-common-enums

Development

# run before development
$ yarn build
# or from the root
$ yarn p:nuxt build

preserveSymlinks could break the module

License

MIT

3.0.0-next.9

8 months ago

3.0.0-next.8

8 months ago

3.0.0-next.7

8 months ago

3.0.0-next.6

1 year ago

3.0.0-next.5

1 year ago

3.0.0-next.4

1 year ago

3.0.0-next.3

1 year ago

3.0.0-next.2

1 year ago

3.0.0-next.1

1 year ago

2.2.0-next.3

1 year ago

2.2.0-next.2

1 year ago

2.2.0-next.1

1 year ago

2.1.3

1 year ago

2.1.2

1 year ago

2.1.1

1 year ago

2.1.0

1 year ago

2.0.0

1 year ago

1.1.2

2 years ago

1.1.1

2 years ago

1.1.0

2 years ago

1.0.0

2 years ago