Giter Site home page Giter Site logo

sam-styles's Introduction

SAM Styles

CircleCI

Fractal

We're using Fractal to generate an interactive component library for sam-styles. You can run it locally after npm install with:

npm start

sam-styles's People

Contributors

ajaybal0082 avatar alejandrocolinagsa avatar annashchelokova avatar ascreven-gsa avatar bibek-regmi avatar carlosvalle avatar christyhermansen avatar cwolf10 avatar davereed avatar irbisthecat avatar julieduong22 avatar julieduong46 avatar samanthabaker avatar shayan-roshan avatar shayan9211 avatar thomastighe avatar tigerligsa avatar tigerpway avatar yerramshilpa avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

sam-styles's Issues

Loading animation is broken

Found in the Entity MFE using @gsa-sam/sam-styles 0.0.151. The loading animations are not working. The boxes are displayed but there is no animation. Looking at the generated styles.css, the animation-name is not matching in case to the @keyframes name (placeHolderShimmer vs. placeholderShimmer). When I manually update the @keyframes name to placeHolderShimmer using Dev Tools in Chrome the animation starts working.

Example html: <div class="sds-load grid-row margin-top-2"><div class="grid-col-12 sds-load__content height-card-lg"></div></div>

Generated styles.css in Chrome browser:
image

Source file in node_modules:
image

Search fixed max width

Fixed max-width (45 rem) in search is causing unaligned content on larger tablets. For example, here is a screenshot of the Assistance Listings landing page in Sam Prototype:
Screen Shot 2020-10-07 at 1 52 13 PM

Can the fixed width be removed? If not, setting it to a USWDS max-width variable would allow surrounding blocks (ie: advanced search) to remain aligned in MFEs if the max width size changes.

(Angular 13) Applies to Formly From - Margin top for address fields are bigger than it used to be

  1. We've updated to Angular 13 and @gsa-sam packages as below:
    "@gsa-sam/components": "13.0.0-beta.3",
    "@gsa-sam/layout": "13.0.0-beta.1",
    "@gsa-sam/layouts": "13.0.0-beta.0",
    "@gsa-sam/ngx-uswds": "13.0.0-beta.1",
    "@gsa-sam/ngx-uswds-icons": "13.0.0-beta.2",
    "@gsa-sam/sam-formly": "13.0.0-beta.3",
    "@gsa-sam/sam-material-extensions": "13.0.0-beta.3",
    "@gsa-sam/sam-styles": "0.0.145",
    "@gsa-sam/shared": "13.0.0-beta.1",
  1. Found that the spaces between address fields are bigger than they are used to be.
  • Notes: The right side is COMP without the updates, and the left side is localhost with the updates in the screenshot.

a,
11  margin-exclusion-SED-address-fields

b,
23  margin-non-fed-entities-validate-entities-

  1. It seems those changes are coming from updating CSS styles below.

11  css-style-minc-vs-comp-margin-exclusion-SED-address-fields

  • Notes: The right side is COMP with the updates, and the left side is MINC without the updates in the screenshot.
formly-field {
    display: block;
    margin-top: 1.5rem;
}
  1. Here is a link of code for formly config (line 136 - line392)
    https://github.helix.gsa.gov/GSA-IAE-APPS/sam-frontend-entity/blob/integration-42.3/apps/entity-tier2/src/app/get-entity-id-V2/entity-form-V2/entity-form-V2.component.ts#L136-L392

(Angular 13) Radio Filters - Margin Issue

RE: IAEMOD-6641

1. We've updated @gsa-sam packages as below:

    "@gsa-sam/components": "13.0.1",
    "@gsa-sam/sam-formly": "13.0.1",
    "@gsa-sam/sam-material-extensions": "13.0.1",
    "@gsa-sam/sam-styles": "0.0.147",
  • Other @gsa-sam packages info, FYI:
    "@gsa-sam/layout": "13.0.0-beta.1",
    "@gsa-sam/layouts": "13.0.0-beta.0",
    "@gsa-sam/ngx-uswds": "13.0.0-beta.1",
    "@gsa-sam/ngx-uswds-icons": "13.0.0-beta.2",
    "@gsa-sam/shared": "12.0.38",

2. Screenshots:

(In the screenshots, the left side is localhost which is after the packages updated, and the right side is 55 Comp before the update)

2a. Exclusions Type label's bottom margin is small.
a exclusions-type-label-pixelized

2b. i. Expiration Date and ii. Address Update labels are close to the their first option.
b  expiration-date_address-update-label

3. Here are formly config:

3a. For #2a above:

    {
      key: 'requestTypesOptions',
      templateOptions: { group: 'panel' },
      fieldGroup: [
        {
          key: 'requestType',
          id: 'requestType',
          type: 'radio',
          defaultValue: 'myexclusions',
          templateOptions: {
            label: 'Exclusions Type',
            hideOptional: true,
            options: [
              // tslint:disable-next-line: max-line-length
              { label: 'Agency Exclusions', value: 'myagencyexclusions', tooltipText: 'Search results will contain all Agency Exclusions.' },
              { label: 'My Exclusions', value: 'myexclusions', tooltipText: "Search results will contain all your Exclusions." }
            ],
            change: (field, $event) => {
              this.applyFilters(field);
            }
          },
          hooks: {
            onInit: (field: FormlyFieldConfig) => {
              if (this.queryParams.requestType != null) {
                field.formControl.setValue(this.queryParams.requestType);
              }
            }
          }
        }
      ]
    },

3b. For #2b-i. Expiration Date above:


  public expirationDateConfig = {
    key: 'expirationDate',
    templateOptions: { label: 'Expiration Date', group: 'accordion' },
    fieldGroup: [
      {
        key: 'expirationDays',
        id: 'exp',
        type: 'radio',
        templateOptions: {
          label: 'Expiration Date',
          hideOptional: true,
          defaultValue: null,
          options: [
            { label: '30 Days', value: '30' },
            { label: '60 Days', value: '60' },
            { label: '90 Days', value: '90' },
            { label: 'All Registrations', value: null }
          ],
          change: (field) => {
            this.applyFilters(field);
          }
        },
        hooks: {
          onInit: (field: FormlyFieldConfig) => {
            if (this.queryParams.expirationDays != null) {
              field.formControl.setValue(this.queryParams.expirationDays);
            }
          }
        }
      }
    ],
  };

3c. For #2b-ii. Address Update above:

  fedHsFieldAddressUpdate = {
    key: 'addressUpdateFlag',
    templateOptions: { label: 'Address Update', group: 'accordion' },
    fieldGroup: [
      {
        key: 'addressUpdateFlag',
        id: 'addr',
        type: 'radio',
        templateOptions: {
          label: 'Address Update',
          hideOptional: true,
          defaultValue: null,
          options: [
            { label: 'Update Required', value: 'Y' },
            { label: 'Update Not Required', value: 'N' },
            { label: 'All Registrations', value: null }
          ],
          change: (field) => {
            this.applyFilters(field);
          }
        },
        hooks: {
          onInit: (field: FormlyFieldConfig) => {
            if (this.queryParams.addressUpdateFlag != null) {
              field.formControl.setValue(this.queryParams.addressUpdateFlag);
            }
          }
        }
      }
    ],
  };

(Angular 13) Tooltip Text Icon - Misaligned with the labels

1. Currently we are on @gsa-sam packages versions as below:

    "@gsa-sam/components": "13.0.7",
    "@gsa-sam/layout": "13.0.4",
    "@gsa-sam/layouts": "13.0.0",
    "@gsa-sam/ngx-uswds": "13.0.0-beta.1",
    "@gsa-sam/ngx-uswds-icons": "13.0.0-beta.2",
    "@gsa-sam/sam-formly": "13.0.7",
    "@gsa-sam/sam-material-extensions": "13.0.7",
    "@gsa-sam/sam-styles": "0.0.151",
    "@gsa-sam/shared": "13.1.13",

2. Screenshot:

2a. Under Exclusions Type, the tooltip icons for Agency Exclusions and My Exclusions looks misaligned:

Tooltip-Misalignment-Exclusion-Workspace-3-29-23

3. Formly config:

3a. Here is formly config for #2a above:

   {
      key: 'requestTypesOptions',
      templateOptions: { group: 'panel' },
      fieldGroup: [
        {
          key: 'requestType',
          id: 'requestType',
          type: 'radio',
          defaultValue: 'myexclusions',
          templateOptions: {
            label: 'Exclusions Type',
            hideOptional: true,
            options: [
              // tslint:disable-next-line: max-line-length
              { label: 'Agency Exclusions', value: 'myagencyexclusions', tooltipText: 'Search results will contain all Agency Exclusions.' },
              { label: 'My Exclusions', value: 'myexclusions', tooltipText: "Search results will contain all your Exclusions." }
            ],
            change: (field, $event) => {
              this.applyFilters(field);
            }
          },
          hooks: {
            onInit: (field: FormlyFieldConfig) => {
              if (this.queryParams.requestType != null) {
                field.formControl.setValue(this.queryParams.requestType);
              }
            }
          }
        }
      ]
    },  

4. Notes:

  • Previously this issue is reported:
    • in FWG Google space on Fed 2, 2023
    • by Github issue: #590

top-margin issue on formly-field

Sam-styles v0.0.144 package includes an addition of top-margin to formly fields. This is causing our formly fields to display with large gaps in between each other. Screenshots attached from T2 workspace and Enter Entity Information page.

Screen Shot 2022-10-05 at 12 17 03 PM

Screen Shot 2022-10-05 at 12 17 49 PM

Uswds3.3: Button hover changes

Fix the uswds 3.3 primary light hover behaviour
3) Base button color is much darker
11) Font weight of a button text changes when hovering
12) For disabled:

  • border line disappears when hovering
  • differences on bg color, text color
  1. Font weight is smaller. Differences on bg color

[UEI 2.0] Status color circle is distorted with long status names

For UEI 2.0 the status names on the Tier 2 workspace are being updated to longer names, e.g., "Submitted" to "Submitted Registration". This is causing the color circles for the status to be distorted.

Code sample:
<span class="sds-tag sds-tag--outline"> <em class="sds-status sds-status--sm sds-status--blue"></em> <span>Submitted Registration</span> </span>

These 3 are more of an oval shape instead of circle:

image

image

image

This is what the circle normally looks like:

image

New Styles Beta - Button Colors

Current packages:
@gsa-sam/[email protected]
@gsa-sam/[email protected]

Is your feature request related to a problem? Please describe.
The updated scss files drastically changed the colors for buttons, as well as changed the sizing.

What is on the uswds branch in sam-frontend-content (local only)
image

Describe the desired solution
The buttons should look like the below picture:
image

Additional context
This is the HTML for this section :
image

Card Body Grid

Landing page example with card body grid is current misaligned (list items with icons) and isn't responsive:

Screen Shot 2020-12-21 at 12 37 12 PM

Screen Shot 2020-12-21 at 12 37 29 PM

RE: Angular 13 update - Warnings started to appear after updating

After updating to Angular 13 and @gsa-sam packages (as below), I see the following warnings started to appear when running localhost npm run start and console in developer's tool in browser.

a. @gsa-sam packages we've updated:

    "@gsa-sam/components": "13.0.0-beta.3",
    "@gsa-sam/layout": "13.0.0-beta.1",
    "@gsa-sam/layouts": "13.0.0-beta.0",
    "@gsa-sam/ngx-uswds": "13.0.0-beta.1",
    "@gsa-sam/ngx-uswds-icons": "13.0.0-beta.2",
    "@gsa-sam/sam-formly": "13.0.0-beta.3",
    "@gsa-sam/sam-material-extensions": "13.0.0-beta.3",
    "@gsa-sam/sam-styles": "0.0.145",
    "@gsa-sam/shared": "13.0.0-beta.1",

b. Warnings in CMD and console in a browser:

Warning: 35 rules skipped due to selector errors:
  .usa-paragraph + * -> Cannot read property 'type' of undefined
  .usa-display + * -> Cannot read property 'type' of undefined
  .usa-display + * -> Cannot read property 'type' of undefined
  .usa-display + * -> Cannot read property 'type' of undefined
  .usa-prose > p + * -> Cannot read property 'type' of undefined
  .usa-prose > .p + * -> Cannot read property 'type' of undefined
  p + * -> Cannot read property 'type' of undefined
  .p + * -> Cannot read property 'type' of undefined
  .usa-prose > h1 + * -> Cannot read property 'type' of undefined
  .usa-prose > h2 + * -> Cannot read property 'type' of undefined
  .usa-prose > h3 + * -> Cannot read property 'type' of undefined
  .usa-prose > h4 + * -> Cannot read property 'type' of undefined
  .usa-prose > h5 + * -> Cannot read property 'type' of undefined
  .usa-prose > h6 + * -> Cannot read property 'type' of undefined
  h1 + * -> Cannot read property 'type' of undefined
  h2 + * -> Cannot read property 'type' of undefined
  h3 + * -> Cannot read property 'type' of undefined
  h4 + * -> Cannot read property 'type' of undefined
  h5 + * -> Cannot read property 'type' of undefined
  h6 + * -> Cannot read property 'type' of undefined
  .usa-graphic-list__heading + * -> Cannot read property 'type' of undefined
  .usa-hero__heading + * -> Cannot read property 'type' of undefined
  .usa-icon-list__title + * -> Cannot read property 'type' of undefined
  .usa-nav__submenu .usa-nav__submenu-item + * -> Cannot read property 'type' of undefined
  .usa-nav__close + * -> Cannot read property 'type' of undefined
  .usa-process-list__heading + * -> Cannot read property 'type' of undefined
  section h1 + * -> Cannot read property 'type' of undefined
  section h2 + * -> Cannot read property 'type' of undefined
  section h3 + * -> Cannot read property 'type' of undefined
  section h4 + * -> Cannot read property 'type' of undefined
  section h5 + * -> Cannot read property 'type' of undefined
  section h6 + * -> Cannot read property 'type' of undefined
  .sds-card__header .sds-card__title + * -> Cannot read property 'type' of undefined
  .sds-toolbar + * -> Cannot read property 'type' of undefined
  .sds-toolbar + * -> Cannot read property 'type' of undefined

Also attaching a screenshot:
9  warnings-npm-run-start

(Angular 13) Applies to Formly Filters - A space between a border and a first list item is smaller than it used to be.

  1. We've updated to Angular 13 and @gsa-sam packages as below:
    "@gsa-sam/components": "13.0.0-beta.3",
    "@gsa-sam/layout": "13.0.0-beta.1",
    "@gsa-sam/layouts": "13.0.0-beta.0",
    "@gsa-sam/ngx-uswds": "13.0.0-beta.1",
    "@gsa-sam/ngx-uswds-icons": "13.0.0-beta.2",
    "@gsa-sam/sam-formly": "13.0.0-beta.3",
    "@gsa-sam/sam-material-extensions": "13.0.0-beta.3",
    "@gsa-sam/sam-styles": "0.0.145",
    "@gsa-sam/shared": "13.0.0-beta.1",
  1. And I found that a space between a border and a first list item is smaller than it used to be which are in following places in the screenshot:
  • Notes: The right side is COMP without the updates, and the left side is localhost with the updates in the screenshot.

a.
2b  exclusion-label-error

b.
8  margin-top-fed-entities-entity-status

c.
17  margin-exclusions-legacy-ct-codes-Exclusions_Type

  1. It seems those changes are coming from updating CSS styles below. Those changes are applied to other places as well, however it seems except for list-items with checkboxes, they look okay IMO.
  • Notes: The right side is COMP with the updates, and the left side is MINC without the updates in the screenshot.
    issue-group-4-ref-8-small-top-margin-checkbox
formly-form .usa-form-group {
    margin-top: 0!important;
}

and

.margin-y-0 {
    margin-top: 0!important;
    margin-bottom: 0!important;
}
  1. Here is code snippet for formly config:
fedHsFields: FormlyFieldConfig[] = [
    this.fedHsFieldKeyword,
    this.searchEntityConfig,
    {
      key: 'status',
      templateOptions: { label: 'Entity Status', group: 'accordion' },
      fieldGroup: [
        {
          key: 'statusId',
          id: 'status',
          type: 'multicheckbox',
          templateOptions: {
            label: 'Entity Status',
            labelClass: 'usa-sr-only',
            hideOptional: true,
            options: [
              {
                key: '1,2',
                value: 'Work in Progress Registration'
              },
              {
                key: '3',
                value: 'Submitted Registration'
              },
              {
                key: '4',
                value: 'Active Registration'
              },
              {
                key: '7',
                value: 'Inactive Registration'
              },
              {
                key: '12',
                value: 'ID Assigned'
              }
            ]
          },
          hooks: {
            onInit: (field: FormlyFieldConfig) => {
              if (this.queryParams.statusId != null) {
                const stats = this.queryParams.statusId.split(',');
                const val = {};
                for (const stat of stats) {
                  if (stat === '1' || stat === '2') {
                    val['1,2'] = true;
                  } else {
                    val[stat] = true;
                  }
                }
                field.formControl.setValue(val);
              }
            }
          }
        }
      ],
    },
    this.expirationDateConfig,
    this.fedHsFieldAddressUpdate
  ];

Feature: Create intro/guidance for alerts

For the alerts section, add an introduction and guidance section to define when to use an alert, which type to select, and how it would show up in different layouts.

Icon Lists

Icon lists are misaligned (icons should be at the start of list items)
Screen Shot 2021-01-20 at 9 45 04 AM

sds-button

When combining the sds-button--circle the inner icon is not centered within the circle but slightly above center. This is also exaggerated when usa-button--base and usa-button--small classes is added to the class, but that may be coloring only.

sds-button--circle with no other classes:
sds-button--circle

sds-button--circle + usa-button--base:
sds-button--circle-sds-button--base

sds-button--circle +usa-button--base + sds-button--small
sds-button--circle-sds-button--base-sds-button--small

Selection Panel Double Border

In selection panel, between options there is a double border. This appears because there is a top and bottom border on all items.

New Styles Beta - Spacing

Current packages:
@gsa-sam/[email protected]
@gsa-sam/[email protected]

What is on the uswds branch in sam-frontend-content (local only):
It appears that icons are not aligned centrally, and there is slightly more space between lines of links in the new uswds branch.
image

Describe the desired solution
The spacing should look like what is currently in comp (/content/contract-data is where I grabbed the examples)
image

Additional context
The html for the first link generated with the new libs:
image

The html for the first link generated in comp:
image

Contrast error 508 testing

I was using WAVE tool to do 508 testing and saw this contrast error for Select a Role drop down field.
image

(Angular 13) Tooltip Text Icon - Misaligned with the labels

RE: IAEMOD-6641

1. We've updated @gsa-sam packages as below:

    "@gsa-sam/components": "13.0.1",
    "@gsa-sam/sam-formly": "13.0.1",
    "@gsa-sam/sam-material-extensions": "13.0.1",
    "@gsa-sam/sam-styles": "0.0.147",
  • Other @gsa-sam packages info, FYI:
    "@gsa-sam/layout": "13.0.0-beta.1",
    "@gsa-sam/layouts": "13.0.0-beta.0",
    "@gsa-sam/ngx-uswds": "13.0.0-beta.1",
    "@gsa-sam/ngx-uswds-icons": "13.0.0-beta.2",
    "@gsa-sam/shared": "12.0.38",

2. Screenshots:

(In the screenshots, the left side is localhost which is after the packages updated, and the right side is Comp before the update)

2a. Under Exclusions Type, the tooltip icons for Agency Exclusions and My Exclusions looks misaligned:
a exclusions-type-label-pixelized

3. Here is formly config:

3a. For #2a above:

    {
      key: 'requestTypesOptions',
      templateOptions: { group: 'panel' },
      fieldGroup: [
        {
          key: 'requestType',
          id: 'requestType',
          type: 'radio',
          defaultValue: 'myexclusions',
          templateOptions: {
            label: 'Exclusions Type',
            hideOptional: true,
            options: [
              // tslint:disable-next-line: max-line-length
              { label: 'Agency Exclusions', value: 'myagencyexclusions', tooltipText: 'Search results will contain all Agency Exclusions.' },
              { label: 'My Exclusions', value: 'myexclusions', tooltipText: "Search results will contain all your Exclusions." }
            ],
            change: (field, $event) => {
              this.applyFilters(field);
            }
          },
          hooks: {
            onInit: (field: FormlyFieldConfig) => {
              if (this.queryParams.requestType != null) {
                field.formControl.setValue(this.queryParams.requestType);
              }
            }
          }
        }
      ]
    },

video player issue

  • Video player component does not display the mute, closed caption, and toggle full screen display (they can still be clicked and tabbed through but not visible to the user)
  • Attached the attached screenshot
    Video Player missing icons

usa-checkbox class in formly adds a white background

With USWDS 2.0 update in sam-styles, formly checkbox now has a white background being added to it as part of usa-checkbox class.
While the background may not be easy to spot in SDS Library website, it is very prominent in Content MFE due to being on top of banner image.
image

IE Accordion

Accordion icon displays with vertical bar in certain situations when opening and closing accordion with IE.
accordion--multiselect
accordion--bordered

Filters Dialog CSS Update

There are a few issues with toolbar dialog that needs to be resolved:
The dialog does not cover fill height of the screen
The cancel and apply buttons should be sticky on dialog header / footer while just the body scrolls. Currently, the entire modal scrolls. Added screenshot below of current look for the filters dialog
Screen Shot 2021-12-20 at 5 23 07 PM

[UEI 2.0] Add style classes for new statistics (widget bubble) colors

We have new status colors defined in Confluence for UEI 2.0 for the Tier 1 Entity Management widget bubbles. Can the following statistics styles please be added? I used specific names like 'active-reg' for our use case but these can be made more generalized if desired. Thank you.

.sam.statistics .active-reg.statistic > .value > .circular {
    background: #E3F5E1;
    border: 1px solid #00A91C;
}
.sam.statistics .active-reg.statistic:hover > .value > .circular {
    color: white;
    background: #00A91C;
}

.sam.statistics .submitted-reg.statistic > .value > .circular {
    background: #E7F6F8;
    border: 1px solid #1A4480;
}
.sam.statistics .submitted-reg.statistic:hover > .value > .circular {
    color: white;
    background: #1A4480;
}

.sam.statistics .wip-reg.statistic > .value > .circular {
    background: #E7F6F8;
    border: 1px solid #009EC1;
}
.sam.statistics .wip-reg.statistic:hover > .value > .circular {
    color: white;
    background: #009EC1;
}

.sam.statistics .idassigned-reg.statistic > .value > .circular {
    background: #FBDCFF;
    border: 1px solid #B69FFF;
}
.sam.statistics .idassigned-reg.statistic:hover > .value > .circular {
    color: white;
    background: #B69FFF;
}

.sam.statistics .pendingidassigned-reg.statistic > .value > .circular {
    background: #FEF0C8;
    border: 1px solid #FBC036;
}
.sam.statistics .pendingidassigned-reg.statistic:hover > .value > .circular {
    color: white;
    background: #FBC036;
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.