Skip to content

Commit

Permalink
release of v10.27 (#3486)
Browse files Browse the repository at this point in the history
  • Loading branch information
tujoworker authored Apr 26, 2024
2 parents f37cd0a + 1a62545 commit e0ffff7
Show file tree
Hide file tree
Showing 821 changed files with 14,411 additions and 5,099 deletions.
1 change: 1 addition & 0 deletions packages/dnb-design-system-portal/gatsby-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ const ignoreAsPage = [
'**/demos/layout/Layout.js',
'**/skip-link-example.tsx',
'**/CardProductsTable.js',
'**/ColorTable.tsx',
'**/assets/*.js',
'**/__utils__/*.{js,ts,tsx}',
// '**/*.mdx',// Use when templates/mdx.tsx in createPage is used
Expand Down
26 changes: 10 additions & 16 deletions packages/dnb-design-system-portal/src/core/ChangeLocale.tsx
Original file line number Diff line number Diff line change
@@ -1,29 +1,23 @@
import React from 'react'
import { Dropdown } from '@dnb/eufemia/src'

import Context from '@dnb/eufemia/src/shared/Context'
import Context, { InternalLocale } from '@dnb/eufemia/src/shared/Context'
import { setLang } from './PortalProviders'
import { Field } from '@dnb/eufemia/src/extensions/forms'

export default function ChangeLocale({ listUSLocale = null, ...props }) {
const { locale, setLocale } = React.useContext(Context)

const date = {
'nb-NO': 'Norsk',
'en-GB': 'English (GB)',
}
if (listUSLocale) {
date['en-US'] = 'English (US)'
}

return (
<Dropdown
<Field.Selection
value={locale}
data={date}
on_change={({ data: { value } }) => {
setLocale(value)
onChange={(value) => {
setLocale(value as InternalLocale)
setLang(value)
}}
{...props}
/>
>
<Field.Option value="nb-NO" title="Norsk" />
<Field.Option value="en-GB" title="English (GB)" />
{listUSLocale && <Field.Option value="en-US" title="English (US)" />}
</Field.Selection>
)
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import enUS from '@dnb/eufemia/src/shared/locales/en-US'
import { isTrue } from '@dnb/eufemia/src/shared/component-helper'
import PortalLayout, { PortalLayoutProps } from './PortalLayout'
import { useThemeHandler } from 'gatsby-plugin-eufemia-theme-handler'
import { InternalLocale } from '@dnb/eufemia/src/shared/Context'

// This ensures we processes also the css prop during build
// More into in the docs: https://emotion.sh/docs/ssr#gatsby
Expand Down Expand Up @@ -86,9 +87,9 @@ function SkeletonEnabled({ children }) {
return children
}

export function getLang(locale = 'nb-NO') {
export function getLang(locale: InternalLocale = 'nb-NO'): InternalLocale {
try {
const l = window.localStorage.getItem('locale')
const l = window.localStorage.getItem('locale') as InternalLocale
if (l) {
locale = l
}
Expand Down
14 changes: 14 additions & 0 deletions packages/dnb-design-system-portal/src/docs/EUFEMIA_CHANGELOG.mdx
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
## April, 23. 2024

- New extension: [Forms](/uilib/extensions/forms/) for applications, including fields such as:
- [PhoneNumber](/uilib/extensions/forms/feature-fields/PhoneNumber/)
- [Currency](/uilib/extensions/forms/feature-fields/Currency/)
- [Date](/uilib/extensions/forms/feature-fields/Date/)
- [Email](/uilib/extensions/forms/feature-fields/Email/)
- [Expiry](/uilib/extensions/forms/feature-fields/Expiry/)
- [NationalIdentityNumber](/uilib/extensions/forms/feature-fields/NationalIdentityNumber/)
- [BankAccountNumber](/uilib/extensions/forms/feature-fields/BankAccountNumber/)
- [OrganizationNumber](/uilib/extensions/forms/feature-fields/OrganizationNumber/)
- [PostalCodeAndCity](/uilib/extensions/forms/feature-fields/PostalCodeAndCity/)
- [SelectCountry](/uilib/extensions/forms/feature-fields/SelectCountry/)

## January, 18. 2024

- New component: [AriaLive](/uilib/components/aria-live)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Before you get started, there are some technical decisions you should know about
- [During prebuild](#during-prebuild)
- [During postbuild](#during-postbuild)

<Hr top="large" light />
<Hr top="large" />

## About technology

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ If you are new to the repository, first check out [what I should know before get

<Toc />

<Hr top="large" light />
<Hr top="large" />

<CloneRepo />
<InstallDependencies />
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,16 @@ title: 'Colors'
icon: 'colors'
---

import ColorsTable from 'Docs/quickguide-designer/colors-table.mdx'
import ColorsTable from 'Docs/quickguide-designer/colors/tables'

# Colors

<VisibilityByTheme hidden="sbanken">
## DNB color table for web

_Note:_ DNB color names for design and development are in English.
## Color table for web

<ColorsTable />

<VisibilityByTheme hidden="sbanken">

## Gradients, shadows, and shades

### Gradients
Expand All @@ -33,13 +32,10 @@ Tints are lighter versions of the color that are made by mixing a color with whi
</VisibilityByTheme>

<VisibilityByTheme visible="sbanken">
## Sbanken color table for web

<ColorsTable />

### Tertiary colors

Tertiary colors are available in Eufemia Web Figma file for Sbanken. These are mainly lighter variations of the secondary colors.
Tertiary colors are mainly lighter variations of the secondary colors.

</VisibilityByTheme>

Expand Down
Loading

0 comments on commit e0ffff7

Please sign in to comment.