Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ runs:
node-version: 20.x
cache: 'npm'

- name: Update npm to 11 # Trusted Publishing requires npm >= 11.5.1
run: npm install -g npm@11
shell: bash

- name: Setup caching dependencies
uses: actions/cache@v4
id: cache-node_modules
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/dev_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ jobs:
publish:
name: Publish v6
environment: development
permissions:
id-token: write # Required for OIDC and npm.js Trusted Publishing
contents: write
runs-on: ubuntu-latest
steps:
- name: Check out repository code
Expand Down
8 changes: 5 additions & 3 deletions .github/workflows/pre_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ jobs:
publish:
name: Publish v6
environment: development
permissions:
id-token: write # Required for OIDC and npm.js Trusted Publishing
contents: write
runs-on: ubuntu-latest
steps:
- name: Check out repository code
Expand All @@ -41,18 +44,17 @@ jobs:
run: npx lerna publish ${{ inputs.version }} --preid next --dist-tag v6-next --force-publish --include-merged-tags --no-private --no-changelog --yes
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Publish to NPM (modified packages)
if: ${{ inputs.version != 'premajor' }}
run: npx lerna publish ${{ inputs.version }} --preid next --dist-tag v6-next --include-merged-tags --no-private --no-changelog --yes
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Deprecate Solar Theme on npm
run: |
DEPRECATION_MESSAGE=$(npm info @refinitiv-ui/solar-theme deprecated)
if [[ -z $DEPRECATION_MESSAGE ]]; then npm deprecate @refinitiv-ui/solar-theme "Solar theme is deprecated. Consider migrating to @refinitiv-ui/halo-theme instead."; fi
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
# The granular access token is required because GitHub/npm.js OIDC does not work with npm deprecate command.
NODE_AUTH_TOKEN: ${{ secrets.NPM_DEPRECATION_TOKEN }}
10 changes: 6 additions & 4 deletions .github/workflows/prod_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ jobs:
environment:
name: production
url: https://ui.refinitiv.com
permissions:
id-token: write # Required for OIDC and npm.js Trusted Publishing
contents: write
runs-on: ubuntu-latest
steps:
- name: Check out repository code
Expand Down Expand Up @@ -50,16 +53,15 @@ jobs:
GH_TOKEN: ${{ secrets.GH_TOKEN }}

- name: Publish to NPM
run: npx lerna publish from-git --dist-tag v6-lts --yes --loglevel verbose
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: npx lerna publish from-git --dist-tag v6-lts --yes

- name: Deprecate Solar Theme on npm
run: |
DEPRECATION_MESSAGE=$(npm info @refinitiv-ui/solar-theme deprecated)
if [[ -z $DEPRECATION_MESSAGE ]]; then npm deprecate @refinitiv-ui/solar-theme "Solar theme is deprecated. Consider migrating to @refinitiv-ui/halo-theme instead."; fi
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
# The granular access token is required because GitHub/npm.js OIDC does not work with npm deprecate command.
NODE_AUTH_TOKEN: ${{ secrets.NPM_DEPRECATION_TOKEN }}

- name: Publish Docs
run: curl -X POST "https://api.cloudflare.com/client/v4/pages/webhooks/deploy_hooks/${{ secrets.CF_DEPLOY_HOOKS_ID }}"
2 changes: 1 addition & 1 deletion .github/workflows/sonarcloud_scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
uses: ./.github/actions/setup

- name: SonarCloud Scan
uses: SonarSource/sonarqube-scan-action@v5
uses: SonarSource/sonarqube-scan-action@v8.2.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -142,4 +142,6 @@ custom-elements.json
/.vscode

# nx
.nx
.nx
.cursor/rules/nx-rules.mdc
.github/instructions/nx.instructions.md
3 changes: 3 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,6 @@ css-properties.less
# Solar themes
**/pearl/**/*
**/charcoal/**/*

/.nx/cache
/.nx/workspace-data
10 changes: 5 additions & 5 deletions documents/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
"description": "Element Framework Documentation",
"engines": {
"node": ">=20.0.0",
"npm": ">=10.0.0"
"npm": ">=11.5.1"
},
"scripts": {
"start:dev": "concurrently \"pandora src dist --watch\" \"serve dist -s\"",
"start": "serve dist -s",
"start:dev": "concurrently \"pandora src dist --watch\" \"http-server dist --proxy http://localhost:8080?\"",
"start": "http-server dist --proxy http://localhost:8080?",
"copy:resources": "cp src/_redirects dist/_redirects && cp -r resources dist/resources",
"prebuild": "rm -rf build && nx run @refinitiv-ui/elements:api-analyzer && node ./scripts/element.injector.js",
"build": "pandora build dist --clean --logo=./resources/images/ef-logo.svg --baseUrl '/v6/'",
Expand All @@ -32,8 +32,8 @@
"license": "Apache-2.0",
"devDependencies": {
"esbuild": "^0.18.1",
"pandora-book": "file:tools/pandora-book-3.0.0-73.tgz",
"serve": "^14.2.0"
"http-server": "^14.1.1",
"pandora-book": "file:tools/pandora-book-3.0.0-73.tgz"
},
"dependencies": {
"@refinitiv-ui/core": "^6.6.2",
Expand Down
8 changes: 7 additions & 1 deletion karma.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,13 @@ if (!argv.watch) {
},
chrome: {
base: 'ChromeHeadless',
flags: ['--no-sandbox', '--disable-setuid-sandbox', '--disable-translate', '--disable-extensions']
flags: [
'--no-sandbox',
'--disable-setuid-sandbox',
'--disable-translate',
'--disable-extensions',
'--window-size=1920,1080'
]
},
ie: {
base: 'IE',
Expand Down
29 changes: 14 additions & 15 deletions nx.json
Original file line number Diff line number Diff line change
@@ -1,29 +1,28 @@
{
"tasksRunnerOptions": {
"default": {
"runner": "nx/tasks-runners/default",
"options": {
"cacheableOperations": ["build", "test", "lint", "package", "prepare"]
}
}
},
"extends": "nx/presets/npm.json",
"$schema": "./node_modules/nx/schemas/nx-schema.json",
"affected": {
"defaultBase": "v6"
},
"targetDefaults": {
"build": {
"dependsOn": ["^build"]
"dependsOn": ["^build"],
"cache": true
},
"build:prod": {
"dependsOn": ["^build:prod"]
},
"prepare": {
"dependsOn": ["^prepare"]
"dependsOn": ["^prepare"],
"cache": true
},
"package": {
"dependsOn": ["^package"]
"dependsOn": ["^package"],
"cache": true
},
"lint": {
"cache": true
},
"test": {
"cache": true
}
}
},
"defaultBase": "v6"
}
Loading
Loading