-
Notifications
You must be signed in to change notification settings - Fork 111
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
Niklas Kiefer
committed
Nov 7, 2023
1 parent
91202c4
commit 55cea38
Showing
22 changed files
with
2,016 additions
and
21 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,15 @@ | ||
@use '@carbon/styles' as * with ( | ||
$font-path: 'https://fonts.camunda.io' | ||
); | ||
@use '@carbon/styles/scss/themes'; | ||
@use '@carbon/styles/scss/theme'; | ||
|
||
@import '@bpmn-io/form-js-carbon-styles/src/carbon-styles'; | ||
|
||
.cds--g10 { | ||
@include theme.theme(themes.$g10); | ||
} | ||
|
||
.cds--g100 { | ||
@include theme.theme(themes.$g100); | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<title>Theming</title> | ||
<link href="https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:ital,wght@0,400;0,600;1,400&display=swap" rel="stylesheet"> | ||
<link href="https://fonts.googleapis.com/css2?family=IBM+Plex+Mono&display=swap" rel="stylesheet"> | ||
<style> | ||
html, body, #container { | ||
margin: 0; | ||
padding: 0; | ||
width: 100vw; | ||
height: 100vh; | ||
} | ||
</style> | ||
</head> | ||
<body class="cds--g10"> | ||
<div id="container" role="main"></div> | ||
<script type="module" src="index.js"></script> | ||
</body> | ||
</html> |
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,9 @@ | ||
import '@bpmn-io/form-js/dist/assets/form-js.css'; | ||
import '@bpmn-io/form-js/dist/assets/form-js-editor.css'; | ||
import '@bpmn-io/form-js/dist/assets/form-js-playground.css'; | ||
|
||
import './theme.scss'; | ||
|
||
import { renderSchema } from '../renderSchema'; | ||
|
||
renderSchema(); |
File renamed without changes.
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,38 @@ | ||
const { expect } = require('@playwright/test'); | ||
|
||
const { test } = require('../test-fixtures'); | ||
|
||
const schema = require('./fixtures/complex.json'); | ||
|
||
test('carbon styles', async ({ page, makeAxeBuilder }) => { | ||
|
||
// given | ||
await page.route('/form', route => { | ||
|
||
route.fulfill({ | ||
status: 200, | ||
body: JSON.stringify({ | ||
data: { | ||
schema, | ||
component: 'viewer' | ||
} | ||
}) | ||
}); | ||
}); | ||
|
||
// when | ||
await page.goto('/carbon'); | ||
|
||
await page.waitForSelector('#container', { | ||
state: 'visible' | ||
}); | ||
|
||
// then | ||
await expect(page).toHaveScreenshot(); | ||
|
||
// and then | ||
const results = await makeAxeBuilder().analyze(); | ||
|
||
expect(results.violations).toHaveLength(0); | ||
expect(results.passes.length).toBeGreaterThan(0); | ||
}); |
Binary file added
BIN
+40.4 KB
e2e/visual/carbon-styles.spec.js-snapshots/carbon-styles-1-chromium-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+65.9 KB
e2e/visual/carbon-styles.spec.js-snapshots/carbon-styles-1-firefox-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+41.1 KB
e2e/visual/carbon-styles.spec.js-snapshots/carbon-styles-1-webkit-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.