Skip to content
This repository has been archived by the owner on Dec 17, 2024. It is now read-only.

Commit

Permalink
Merge pull request #427 from web-illinois/develop
Browse files Browse the repository at this point in the history
Merge for 2.15
  • Loading branch information
bryanjonker-illinois authored Mar 3, 2023
2 parents 354f8ae + d048537 commit 378303a
Show file tree
Hide file tree
Showing 113 changed files with 1,951 additions and 28 deletions.
71 changes: 49 additions & 22 deletions backstop.config.js
Original file line number Diff line number Diff line change
@@ -1,32 +1,59 @@
const glob = require('fast-glob');
const path = require('path');
const util = require('./tests/tests.util');
const viewports = require('./viewports.json');

function makeId(file, config) {
const relativePath = path.relative('tests', file);
let id = relativePath.replace(/\.vis\.js$/, '').replace(/[\\\/]/g, '_');
if (config.test) {
id += '_' + config.test;
}
else if (config.variant) {
id += '_' + config.variant;
}
else if (config.suffix) {
id += '_' + config.suffix;
}
return id;
}

const scenarios = [];
glob.sync('tests/**/*.vis.js').forEach(file => {
const fileScenarios = require(path.join(__dirname, file))(viewports);
fileScenarios.forEach(s => s.file = file);
scenarios.push(...fileScenarios);
const filePath = path.join(__dirname, file);
const fileScenarios = require(filePath)(viewports);
fileScenarios.forEach(s => {
const id = makeId(file, s);
s.file = file;
if (!s.url) {
s.url = util.testUrl(filePath);
}
if (!s.label) {
s.label = id;
}
});
scenarios.push(...fileScenarios);
})

module.exports = {
"id": "web-toolkit",
"viewports": Object.values(viewports),
"scenarios": scenarios,
"paths": {
"bitmaps_reference": "tests/_reference",
"engine_scripts": "tests/_scripts",
"bitmaps_test": "var/backstop/images",
"html_report": "var/backstop/html",
},
"report": ["browser"],
"engine": "puppeteer",
"engineOptions": {
"args": ["--no-sandbox"]
},
"onReadyScript": "onReady.js",
"asyncCaptureLimit": 5,
"dockerCommandTemplate": "docker run -e BACKSTOP_ENV=docker --rm -it --mount type=bind,source=\"{cwd}\",target=/src backstopjs/backstopjs:{version} {backstopCommand} {args}",
"debugWindow": false,
"debug": false
id: "web-toolkit",
//fileNameTemplate: '{scenarioLabel}_{viewportLabel}',
viewports: Object.values(viewports),
scenarios: scenarios,
paths: {
bitmaps_reference: "tests/_reference",
engine_scripts: "tests/_scripts",
bitmaps_test: "var/backstop/images",
html_report: "var/backstop/html",
},
report: ["browser"],
engine: "puppeteer",
engineOptions: {
args: ["--no-sandbox"]
},
onReadyScript: "onReady.js",
asyncCaptureLimit: 5,
dockerCommandTemplate: "docker run -e BACKSTOP_ENV=docker --rm -it --mount type=bind,source=\"{cwd}\",target=/src backstopjs/backstopjs:{version} {backstopCommand} {args}",
debugWindow: false,
debug: false
};
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "il-toolkit",
"version": "2.14.1",
"version": "2.15.0",
"description": "Web toolkit",
"repository": "https://github.com/web-illinois/toolkit",
"author": "Web Implementation Guidelines Group",
Expand All @@ -23,6 +23,7 @@
"dependencies": {
"@symfony/webpack-encore": "^0.30.2",
"lit": "^2.0.0-rc.3",
"node": "^14.17.4",
"remove-files-webpack-plugin": "^1.4.4",
"sass": "^1.44.0",
"sass-loader": "^8.0.2"
Expand Down
90 changes: 90 additions & 0 deletions src/css/_placeholders.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
/*
> * {
@include reset-spacing;
text-align: left !important;
display: block;
margin-bottom: .25em;
font-size: rem(18px);
font-weight: 400;
line-height: 1.2em;
font-family: var(--il-font-sans);
}
> *:first-child {
margin-top: -2px;
}
> *:last-child {
margin-bottom: -2px;
font-weight: 600;
line-height: 1em;
color: var(--il-blue);
}
a {
@extend .il-link;
color: var(--il-blue) !important;
text-decoration: none !important;
}
a:focus, a:hover {
color: var(--il-altgeld) !important;
outline: none;
}
h1 {
@include reset-spacing;
font-size: rem(24px);
}
.il-primary-unit {
display: none;
}
@media (min-width: 768px) {
.il-primary-unit {
display: block;
}
}
*/

%site-name, %site-parent-name {
margin: 0;
padding: 0;
text-align: left;
line-height: 1.25;
font-family: var(--il-source-sans);
color: var(--il-blue);

a {
color: inherit;
text-decoration: none;

&:hover, &:focus {
color: var(--il-altgeld);
}

&:focus {
outline: 2px dotted var(--il-altgeld);
outline-offset: 2px;
}
}
}

%site-name {
font-weight: 600;
font-size: 1.5em;
}

%site-parent-name {
font-weight: 400;
font-size: 1.125em;
}

%site-identity {
font-size: 1.5rem;

> * {
@extend %site-parent-name;

&:last-child {
@extend %site-name;
}
}
}
5 changes: 5 additions & 0 deletions src/css/components/_accordion.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
il-accordion-panel {
border: var(--il-details-border);
max-width: var(--il-details-maxwidth);
margin: 20px 0;
}
3 changes: 3 additions & 0 deletions src/css/components/_index.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
@import 'accordion';
@import 'back-to-top';
@import 'breadcrumbs';
@import 'call-to-action';
Expand All @@ -9,11 +10,13 @@
@import 'hero';
@import 'image-feature';
@import 'image-feature-with-overlay';
@import 'introduction';
@import 'lede';
@import 'navigation';
@import 'page-title';
@import 'quote';
@import 'section-nav';
@import 'statistic';
@import 'unit-wordmark';
@import 'vertical-tab';
@import 'video';
20 changes: 20 additions & 0 deletions src/css/components/_introduction.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
il-introduction, .il-formatted il-introduction {
display: block;
background: var(--il-background-color);
color: var(--il-heading-color);
padding: 30px;

&.il-align-center {
text-align: center;
}

a.il-button, button.il-button {
margin-right: 20px;
}
}

@media only screen and (max-width: 792px) {
il-introduction, .il-formatted il-introduction {
padding: 20px;
}
}
39 changes: 39 additions & 0 deletions src/css/components/_vertical-tab.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
:root {
--il-panel-background-color: var(--il-blue);
--il-panel-foreground-color: white;
--il-panel-text-color: white;
--il-panel-title-color: var(--il-orange);
--il-panel-border: 1px solid #C8C6C7;
--il-panel-link-focused-color: var(--il-orange);
--il-selected-panel-background-color: var(--il-orange);
--il-selected-panel-foreground-color: white;
--il-focused-panel-background-color: var(--il-blue-darker-1);
--il-focused-panel-foreground-color: white;
}

il-vertical-tab, .il-formatted il-vertical-tab {
display: block;
background: var(--il-panel-background-color);

h2, h3, h4, h5, h6, p {
color: var(--il-panel-text-color);
}

il-vertical-tab-panel, .il-formatted il-vertical-tab-panel {
h2, h3, h4, h5, h6 {
color: var(--il-panel-title-color);
}
p, ul, a, a:visited {
color: var(--il-panel-text-color);
}
a:focus, a:hover {
color: var(--il-panel-link-focused-color);
}
}

@media only screen and (max-width: 792px) {
il-vertical-tab-panel:first-of-type {
border-top: var(--il-panel-border);
}
}
}
2 changes: 2 additions & 0 deletions src/css/details.scss
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
--il-details-background: var(--il-gray-1);
--il-details-background-hover: var(--il-cloud-2);
--il-details-color: var(--il-blue);
--il-details-padding: 30px 0px 30px 10px;
--il-details-border: none;
--il-details-bordered-marginleft: 48px;
--il-details-animation: none;
--il-details-bordered-maxwidth: 900px;
Expand Down
4 changes: 1 addition & 3 deletions src/css/styles.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
$base-text-size: 18px;

@import "mixins";
@import "placeholders";

@import "reset";
@import "colors";
Expand Down Expand Up @@ -95,9 +96,6 @@ $base-text-size: 18px;

@import "layout";
@import "typography";

@import "buttons";

@import "details";

@import "themes";
10 changes: 10 additions & 0 deletions src/css/themes/_gray.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,14 @@
--il-focused-button-background-color: var(--il-blue);
--il-focused-button-foreground-color: white;
--il-focused-button-border-color: var(--il-blue);

--il-panel-background-color: var(--il-gray-1);
--il-panel-foreground-color: var(--il-blue);
--il-panel-text-color: var(--il-blue);
--il-panel-title-color: var(--il-blue);
--il-panel-border: 2px solid var(--il-industrial-blue);
--il-selected-panel-background-color: var(--il-orange);
--il-selected-panel-foreground-color: var(--il-gray-1);
--il-focused-panel-background-color: var(--il-blue);
--il-focused-panel-foreground-color: white;
}
15 changes: 15 additions & 0 deletions src/css/themes/_white.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,19 @@
--il-focused-button-background-color: var(--il-blue);
--il-focused-button-foreground-color: white;
--il-focused-button-border-color: var(--il-blue);

--il-panel-background-color: white;
--il-panel-foreground-color: var(--il-blue);
--il-panel-text-color: var(--il-blue);
--il-panel-title-color: var(--il-blue);
--il-panel-border: 2px solid var(--il-industrial-blue);
--il-selected-panel-background-color: var(--il-orange);
--il-selected-panel-foreground-color: white;
--il-focused-panel-background-color: var(--il-blue);
--il-focused-panel-foreground-color: white;

--il-details-color: var(--il-blue);
--il-details-background: white;
--il-details-background-hover: var(--il-cloud-2);
--il-details-border: thin solid var(--il-blue);
}
43 changes: 43 additions & 0 deletions src/images/fingerprint-1400x78.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 378303a

Please sign in to comment.