-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
55 changed files
with
2,447 additions
and
266 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
'@vintl/vintl': minor | ||
--- | ||
|
||
Add more formatting components similar to `react-intl` | ||
|
||
- `FormattedDate`, `FormattedDateParts` | ||
- `FormattedTime`, `FormattedTimeParts` | ||
- `FormattedDateTimeRange` | ||
- `FormattedRelativeTime` (static, unlike `react-intl`) | ||
- `FormattedNumber`, `FormattedNumberParts` | ||
- `FormattedPlural` | ||
- `FormattedList`, `FormattedListParts` | ||
- `FormattedDisplayName` | ||
- `FormattedMessage` | ||
|
||
Since this is a Vue library, they use slots to pass formatted values (otherwise rendering them as is). | ||
|
||
`FormattedMessage` is very similar to `IntlFormatted`, but accepts descriptor properties and does not allow to format raw messages. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
--- | ||
'@vintl/vintl': major | ||
--- | ||
|
||
Remove deprecated composables | ||
|
||
Composables, such as `useI18n`, `useTranslate` and `useFormatters` were previously deprecated with the warning that they will be removed in the next major version. They now get removed as scheduled. | ||
|
||
Migration steps: | ||
|
||
- Use `useVIntl` everywhere you used `useI18n`, the latter was just an alias for `useVIntl` in previous versions. | ||
|
||
- To retrieve translate function previously returned by `useTranslate`, destructure `formatMessage` function from the controller: | ||
|
||
```js | ||
const { formatMessage } = useVIntl | ||
``` | ||
|
||
It is bound to the controller and as such is safe to use on its own. | ||
|
||
- To retrieve formatters previously returned by `useFormatters`, destructure `formats` property from the controller: | ||
|
||
```js | ||
const { formats } = useVIntl | ||
``` | ||
|
||
It is reactively updated object and also safe to use on its own. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
'@vintl/vintl': major | ||
--- | ||
|
||
Bump Vue version to 3.3.4 | ||
|
||
We're now requiring a newer Vue version because we are relying on functionality added in Vue 3.3, such as generic components. Since it's not compatible with previous versions of Vue, this is marked as a breaking change. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"mode": "pre", | ||
"tag": "next", | ||
"initialVersions": { | ||
"@vintl/vintl": "4.2.0" | ||
}, | ||
"changesets": [] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
'@vintl/vintl': minor | ||
--- | ||
|
||
Add `useMessages` composable | ||
|
||
v5 introduces a new API that allows you to create messages more effectively. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.