style: update mentions
parent
bfbcdaf9b0
commit
c341258241
|
@ -9,7 +9,7 @@ Mention component.
|
||||||
|
|
||||||
## When To Use
|
## When To Use
|
||||||
|
|
||||||
- When need to mention someone or something.
|
When you need to mention someone or something.
|
||||||
|
|
||||||
## API
|
## API
|
||||||
|
|
||||||
|
|
|
@ -29,8 +29,8 @@ interface MentionsEntity {
|
||||||
|
|
||||||
export type MentionPlacement = 'top' | 'bottom';
|
export type MentionPlacement = 'top' | 'bottom';
|
||||||
|
|
||||||
const getMentions = (value = '', config: MentionsConfig): MentionsEntity[] => {
|
const getMentions = (value = '', config: MentionsConfig = {}): MentionsEntity[] => {
|
||||||
const { prefix = '@', split = ' ' } = config || {};
|
const { prefix = '@', split = ' ' } = config;
|
||||||
const prefixList: string[] = Array.isArray(prefix) ? prefix : [prefix];
|
const prefixList: string[] = Array.isArray(prefix) ? prefix : [prefix];
|
||||||
|
|
||||||
return value
|
return value
|
||||||
|
|
|
@ -37,6 +37,7 @@
|
||||||
overflow: inherit;
|
overflow: inherit;
|
||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
|
/* stylelint-disable declaration-block-no-redundant-longhand-properties */
|
||||||
font-weight: inherit;
|
font-weight: inherit;
|
||||||
font-size: inherit;
|
font-size: inherit;
|
||||||
font-family: inherit;
|
font-family: inherit;
|
||||||
|
@ -45,6 +46,7 @@
|
||||||
font-size-adjust: inherit;
|
font-size-adjust: inherit;
|
||||||
font-stretch: inherit;
|
font-stretch: inherit;
|
||||||
line-height: inherit;
|
line-height: inherit;
|
||||||
|
/* stylelint-enable declaration-block-no-redundant-longhand-properties */
|
||||||
direction: inherit;
|
direction: inherit;
|
||||||
letter-spacing: inherit;
|
letter-spacing: inherit;
|
||||||
white-space: inherit;
|
white-space: inherit;
|
||||||
|
|
Loading…
Reference in New Issue