Security News
NIST Misses 2024 Deadline to Clear NVD Backlog
NIST has failed to meet its self-imposed deadline of clearing the NVD's backlog by the end of the fiscal year. Meanwhile, CVE's awaiting analysis have increased by 33% since June.
@rei/cdr-list
Advanced tools
For the most up-to-date information, see REI Cedar documentation.
name | type | default |
---|---|---|
Tag | string | 'ul' |
Sets valid HTML element tag for lists. Possible values: { ‘ul’ | ‘ol’ } |
name | type | default |
---|---|---|
modifier | string | N/A |
Modifies the style variant for this component. Possible values: { ‘ordered’ | ‘unordered’ | ‘compact’ |
name |
---|
default |
Sets the innerHTML for cdr-list. This includes text and html markup |
Resources are available within the CdrList package:
@rei/cdr-list
cdr-list.css
To incorporate the required assets for a component, use the following steps:
Install the CdrList
package using npm
in your terminal:
Terminal
npm i -s @rei/cdr-list
main.js
// import your required css.
import "@rei/cdr-list/dist/cdr-list.css";
local.vue
<template>
<cdr-list>
<li> item one </li>
<li> item two </li>
</cdr-list>
</template>
<script>
import { CdrList } from "@rei/cdr-list";
export default {
components: {
CdrList
}
};
</script>
Visual style and semantic meaning are managed independently by providing:
tag
propmodifier
propBy default the CdrList
component renders as an unordered and undecorated "bare" list. To use an ordered list pass <ol>
to the tag property.
<cdr-list tag="ol">
<li> item one </li>
<li> item two </li>
</cdr-list>
The CdrList
component has decoupled the semantic tags <ul>
and <ol>
from visual presentation. It is possible to render a semantic ordered list <ol>
as a visually non styled or bulleted list using the cdr-list
modifiers. With this decoupling, individual list items can contain a variety of HTML elements, including paragraphs, headings, form elements, and other (nested) lists. Ensure that content is structured and follows design guidelines.
Following are different types of lists:
<ul>
element and multiple list item <li>
elements<ol>
element and multiple list item <li>
elementscdr-list
can be nested into another list<cdr-list>
<li> Unordered list item text
<cdr-list tag="ol">
<li>Ordered list item text</li>
</cdr-list>
</li>
</cdr-list>
Note that the tag itself does not determine display, a modifier must be added for list styles. Add one of the following variants to the modifier
attribute of the cdr-list
tag to change the visual presentation:
Name | Description | Example |
---|---|---|
unordered | The unordered modifier adds a bullet decorator to child list items and a ‘en-dash’ decorator to grandchild list items. This variant can be used on both <ul> or <ol> list types. | <cdr-list modifier="unordered" > |
ordered | The ordered modifier adds a numeric decorator to child list items and a ‘en-dash’ decorator to grandchild list items. This variant can be used on both <ul> or <ol> list types. | <cdr-list tag="ol" modifier="ordered" > |
compact | The compact modifier reduces the vertical space between list items for non-inline list variants. For inline variants the compact modifier reduces the horizontal space between list items. | <cdr-list modifier="compact"> |
inline | The inline modifier is intended for bare or unordered list variants. In ether case this can be combined with compact to adjust the spacing of inline list variants. | <cdr-list modifier=" inline"> |
FAQs
REI Cedar Style Framework - Vue Component for List
We found that @rei/cdr-list demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 9 open source maintainers collaborating on the project.
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.
Security News
NIST has failed to meet its self-imposed deadline of clearing the NVD's backlog by the end of the fiscal year. Meanwhile, CVE's awaiting analysis have increased by 33% since June.
Security News
Cloudflare has launched a setup wizard allowing users to easily create and manage a security.txt file for vulnerability disclosure on their websites.
Security News
The Socket Research team breaks down a malicious npm package targeting the legitimate DOMPurify library. It uses obfuscated code to hide that it is exfiltrating browser and crypto wallet data.