mirror of
https://github.com/ArthurDanjou/artsite.git
synced 2026-02-09 21:05:57 +01:00
Enhance: Update Activity component and ProseIcon styles
- Added optional 'assets' field to LanyardActivity interface for small text. - Introduced 'Cursor' IDE to the IDEs list. - Improved color variant styles in ProseIcon component for better visibility. - Refactored Activity component to handle 'Cursor' IDE and updated activity message formatting.
This commit is contained in:
8
types.ts
8
types.ts
@@ -32,6 +32,9 @@ interface LanyardActivity {
|
||||
timestamps: {
|
||||
start: number
|
||||
}
|
||||
assets?: {
|
||||
small_text: string
|
||||
}
|
||||
}
|
||||
|
||||
export interface Activity {
|
||||
@@ -45,6 +48,7 @@ export const IDEs = [
|
||||
{ name: 'IntelliJ IDEA Ultimate', icon: 'i-logos:intellij-idea' },
|
||||
{ name: 'WebStorm', icon: 'i-logos:webstorm' },
|
||||
{ name: 'PyCharm Professional', icon: 'i-logos:pycharm' },
|
||||
{ name: 'Cursor', icon: 'i-vscode-icons-file-type-cursorrules' },
|
||||
]
|
||||
|
||||
export const activityMessages = {
|
||||
@@ -66,13 +70,13 @@ export const activityMessages = {
|
||||
invalid: '',
|
||||
},
|
||||
fr: {
|
||||
justNow: 'à l’instant',
|
||||
justNow: 'à l\'instant',
|
||||
past: (n: string) => (n.match(/\d/) ? `il y a ${n}` : n),
|
||||
future: (n: string) => (n.match(/\d/) ? `dans ${n}` : n),
|
||||
month: (n: number, past: boolean) =>
|
||||
n === 1 ? (past ? 'le mois dernier' : 'le mois prochain') : `${n} mois`,
|
||||
year: (n: number, past: boolean) =>
|
||||
n === 1 ? (past ? 'l’année dernière' : 'l’année prochaine') : `${n} ans`,
|
||||
n === 1 ? (past ? 'l\'année dernière' : 'l\'année prochaine') : `${n} ans`,
|
||||
day: (n: number, past: boolean) =>
|
||||
n === 1 ? (past ? 'hier' : 'demain') : `${n} jours`,
|
||||
week: (n: number, past: boolean) =>
|
||||
|
||||
Reference in New Issue
Block a user