Skip to content

Commit

Permalink
Merge pull request #13 from michealparks/internals-3
Browse files Browse the repository at this point in the history
Rename providers, fix Svelte 5 reactivity issues
  • Loading branch information
michealparks authored Jun 22, 2024
2 parents d8dd515 + b362487 commit 5bcffcd
Show file tree
Hide file tree
Showing 21 changed files with 368 additions and 283 deletions.
5 changes: 5 additions & 0 deletions .changeset/sour-zebras-itch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'threlte-uikit': minor
---

Rename providers, fix Svelte 5 reactivity issues
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,22 +54,22 @@ The vanilla object may be accessed via the `ref` property.

## Context providers

- `createDefaultProperties()`
- `provideDefaultProperties()`

Allows overriding the default properties for all UIKit components and children components of the component in which it is called.

```ts
createDefaultProperties({
provideDefaultProperties({
margin: 10,
})
```

- `createFontFamilies()`
- `provideFontFamilies()`

Provides new font families to all children. Instructions for creating fonts that can be consumed by UIKit can be found [here](https://docs.pmnd.rs/uikit/tutorials/custom-fonts).

```ts
createFontFamilies({
provideFontFamilies({
roboto: {
light: 'url-to-json',
medium: 'url-to-json',
Expand Down
Loading

0 comments on commit 5bcffcd

Please sign in to comment.