Socket
Socket
Sign inDemoInstall

@salesforce/bt-cards-component-example

Package Overview
Dependencies
0
Maintainers
51
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @salesforce/bt-cards-component-example

This is a cards component.


Version published
Weekly downloads
2
increased by100%
Maintainers
51
Install size
11.1 kB
Created
Weekly downloads
 

Readme

Source

About

A component-xxx is a read-only element used to do xxx. Use component-xxx to help. Explain what your component does.

loom - Teaching Entrepreneurship

See Loom video

How to Getting Started

Let's start by installing component-xxx as a dependency of your project with npm or directly the component .copy and past npm package here

specification

Component-XXX Integration

Reusing component-xxx in SFDX LWC Project or Scratch Orgs ONLY.

the component directly.

This component is a shipped LWC version. That will be run inside a scratch org. Component is composed of the following components:

component-xxx.htmlThis is the html view of the component wrapped around the template tag.
component-xxx.cssThe CSS file specific to component-xxx only. It does not include the styles for it's parent sds-badge. c360-badge extends from sds-badge
component-xxx.tsThis is a LWC specific function. This can be used for adding logic for both the css/html and at the same time apex logic
component-xxx.xmlThis file is required if you are planning on deploying component-xxx to a scratch org.
This would be under shipped components.

Reusing component-xxx in LWC OSS ONLY.

Run the following component

npm i @help/component-xxx

For Lightning Web Component (LWC OSS) Integration

/* myComponent.css */

@import "@salesforce-ux/c360-styling-hooks/dist/hooks.custom-props.css";

/* myComponent.js */

import "@salesforce-ux/c360-styling-hooks/dist/hooks.custom-props.css";

import C360Badge from "@salesforce-ux/c360-badge/dist/badge";

window.customElements.define('c360-badge', C360Badge);

HTML Decoration
After that,the HTML of your LWC component template needs to be decorated to have all the named part attributes as per the component's specification. Below is a reference to the component's structure.

Properties & Attributes

AttributeTypeDefault ValueDescription
typestatus/product/default/transparentemptySet the type of the badge
valuesuccess/analytics/redemptySet the appropriate state of the badge based on type. Refer below table
Accepted values for various type
TypeValue
statussuccess/error/warning
productanalytics/service/platform/sales/industry/commerce/employees/learning/experience/work
default/transparent

red/pink/violet/purple/indigo/blue/cloud-blue/teal/green/yellow/orange/ hot-orange

Accessibility

Roles

Please provide an overview of accessibility considerations for your component. ARIA landmark role

Answer the following questions? Is this an interactive element? As component-xxx is an interactive/non-interactive element, this is not by default focusable by keyboard. Please use appropriate tabindex besides role attribute to make them accessible for keyboard interaction.

Extras

Push Requests component-xxx

If you noticed something wrong with the component please feel free to make changes to it. However this change will note override the base component. There will be approval needed for this component.

  1. Fork the following github component-xxx once this is done make the relevant changes to the following components.
  2. Make sure to rename your component component-xxx-extended
  3. Make the changes to this component to either HTML, CSS, or XML of of component-xxx-extended
  4. Package the component A. Run the following: i. Lerna changed - this will show you changed component ii. Lerna bootstrap - This will bundle your component as an npm package iii. Lerna publish - This will publish your component to npm www.npmjs.com. Note you will need to be authenticated to npm in order to do this. Run the following command. npm adduser to authenticate in your terminal
  5. Commit the changes and assign your dedicated reviewer within your BPG review the component.

Note: If you make changes more than once to the component ensure you package the component and classify the component as either Patch MINOR or Major when running lerna bootstrap.

Developer Support

Currently the support for these components is the creator: e.g. Damilare Olowoniyi ( Add Slack Link ). **

Team Support

Please contact #bt-design-bpg-storybooks

If you have any question about this component.

Continuous Integration for Chromatic

https://www.chromatic.com/docs/circleci

Documentation other CI tools:

https://www.chromatic.com/docs/github-actions

FAQs

Last updated on 30 May 2022

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc