cozy-ui 125.1.0 → 126.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +20 -0
- package/assets/icons/illus/only-office.svg +1 -0
- package/package.json +1 -1
- package/react/Icon/Readme.md +3 -1
- package/react/Icons/OnlyOffice.jsx +71 -0
- package/react/QualificationIcon/Readme.md +14 -0
- package/react/{QualificationIconStack → QualificationIcon}/index.jsx +7 -34
- package/react/QualificationModal/helpers.js +6 -6
- package/react/index.js +1 -1
- package/transpiled/react/Icon/icons-sprite.d.ts +1 -1
- package/transpiled/react/Icon/icons-sprite.js +1 -1
- package/transpiled/react/Icons/OnlyOffice.d.ts +2 -0
- package/transpiled/react/Icons/OnlyOffice.js +67 -0
- package/transpiled/react/{QualificationIconStack → QualificationIcon}/index.d.ts +3 -3
- package/transpiled/react/{QualificationIconStack → QualificationIcon}/index.js +14 -38
- package/transpiled/react/QualificationModal/helpers.js +8 -7
- package/transpiled/react/index.d.ts +1 -1
- package/transpiled/react/index.js +1 -1
- package/react/QualificationIconStack/Readme.md +0 -14
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,23 @@
|
|
|
1
|
+
# [126.1.0](https://github.com/cozy/cozy-ui/compare/v126.0.0...v126.1.0) (2025-06-13)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* Add OnlyOffice icon ([fd8d3c0](https://github.com/cozy/cozy-ui/commit/fd8d3c0))
|
|
7
|
+
|
|
8
|
+
# [126.0.0](https://github.com/cozy/cozy-ui/compare/v125.1.0...v126.0.0) (2025-06-11)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* Add new QualificationIcon and use it in QualificationModal ([65cadc4](https://github.com/cozy/cozy-ui/commit/65cadc4))
|
|
14
|
+
* Remove QualificationIconStack component ([d520f80](https://github.com/cozy/cozy-ui/commit/d520f80))
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
### BREAKING CHANGES
|
|
18
|
+
|
|
19
|
+
* You must replace `QualificationIconStack` by `QualificationIcon`
|
|
20
|
+
|
|
1
21
|
# [125.1.0](https://github.com/cozy/cozy-ui/compare/v125.0.0...v125.1.0) (2025-06-11)
|
|
2
22
|
|
|
3
23
|
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_6882_51948)" fill-rule="evenodd" clip-rule="evenodd"><path d="m7 15.172-6.58-3.02c-.56-.264-.56-.672 0-.912l2.291-1.055 4.265 1.966c.56.264 1.463.264 1.999 0l4.265-1.966 2.29 1.055c.561.264.561.671 0 .911l-6.58 3.021c-.511.24-1.413.24-1.95 0Z" fill="url(#paint0_linear_6882_51948)"/><path d="M7 11.456.42 8.436c-.56-.265-.56-.672 0-.912l2.243-1.03L7 8.483c.56.263 1.462.263 1.998 0l4.338-1.99 2.242 1.03c.561.264.561.671 0 .911L9 11.456c-.56.264-1.462.264-1.998 0Z" fill="url(#paint1_linear_6882_51948)"/><path d="M7 7.836.42 4.815c-.56-.264-.56-.672 0-.911L7 .883c.561-.264 1.463-.264 2 0l6.58 3.02c.56.264.56.672 0 .912L9 7.835c-.561.24-1.463.24-2 0Z" fill="url(#paint2_linear_6882_51948)"/></g><defs><linearGradient id="paint0_linear_6882_51948" x1="7.994" y1="18.035" x2="7.994" y2="7.007" gradientUnits="userSpaceOnUse"><stop stop-color="#FCC2B1"/><stop offset=".885" stop-color="#D9420B"/></linearGradient><linearGradient id="paint1_linear_6882_51948" x1="7.994" y1="13.26" x2="7.994" y2="6.007" gradientUnits="userSpaceOnUse"><stop stop-color="#DEEDC9"/><stop offset=".661" stop-color="#8BBA25"/></linearGradient><linearGradient id="paint2_linear_6882_51948" x1="7.994" y1="10.323" x2="7.994" y2=".453" gradientUnits="userSpaceOnUse"><stop stop-color="#C2EBFA"/><stop offset="1" stop-color="#26A8DE"/></linearGradient><clipPath id="clip0_6882_51948"><path fill="#fff" transform="translate(0 .556)" d="M0 0h16v14.889H0z"/></clipPath></defs></svg>
|
package/package.json
CHANGED
package/react/Icon/Readme.md
CHANGED
|
@@ -735,6 +735,7 @@ import KeychainIcon from 'cozy-ui/transpiled/react/Icons/Keychain'
|
|
|
735
735
|
import LogoutLargeIcon from 'cozy-ui/transpiled/react/Icons/LogoutLarge'
|
|
736
736
|
import MailIcon from 'cozy-ui/transpiled/react/Icons/Mail'
|
|
737
737
|
import NotesIcon from 'cozy-ui/transpiled/react/Icons/Notes'
|
|
738
|
+
import OnlyOfficeIcon from 'cozy-ui/transpiled/react/Icons/OnlyOffice'
|
|
738
739
|
import PapersIcon from 'cozy-ui/transpiled/react/Icons/Papers'
|
|
739
740
|
import PassIcon from 'cozy-ui/transpiled/react/Icons/Pass'
|
|
740
741
|
import ShareGrey08Icon from 'cozy-ui/transpiled/react/Icons/ShareGrey08'
|
|
@@ -786,6 +787,7 @@ const icons = [
|
|
|
786
787
|
LogoutLargeIcon,
|
|
787
788
|
MailIcon,
|
|
788
789
|
NotesIcon,
|
|
790
|
+
OnlyOfficeIcon,
|
|
789
791
|
PapersIcon,
|
|
790
792
|
PassIcon,
|
|
791
793
|
ShareGrey08Icon,
|
|
@@ -1018,7 +1020,7 @@ import Typography from 'cozy-ui/transpiled/react/Typography'
|
|
|
1018
1020
|
import Grid from 'cozy-ui/transpiled/react/Grid'
|
|
1019
1021
|
import Sprite from 'cozy-ui/transpiled/react/Icon/Sprite'
|
|
1020
1022
|
|
|
1021
|
-
const availableIcons = ['account', 'bottom-select', 'check-white', 'cloud-broken', 'contacts', 'cozy-authentification', 'cozy-logo', 'cozy-upgrade', 'credit-card-large', 'dash-white', 'device-browser', 'device-laptop', 'device-phone', 'device-tablet', 'file-type-audio', 'file-type-banking-account' , 'file-type-bin', 'file-type-code', 'file-type-files', 'file-type-folder', 'file-type-server', 'file-type-image', 'file-type-note', 'file-type-pdf', 'file-type-sheet', 'file-type-slide', 'file-type-text', 'file-type-video', 'file-type-zip', 'forbidden-sign', 'google', 'keychain', 'logout-large', 'papers', 'store', 'top-select', 'trash-duotone', 'cozy']
|
|
1023
|
+
const availableIcons = ['account', 'bottom-select', 'check-white', 'cloud-broken', 'contacts', 'cozy-authentification', 'cozy-logo', 'cozy-upgrade', 'credit-card-large', 'dash-white', 'device-browser', 'device-laptop', 'device-phone', 'device-tablet', 'file-type-audio', 'file-type-banking-account' , 'file-type-bin', 'file-type-code', 'file-type-files', 'file-type-folder', 'file-type-server', 'file-type-image', 'file-type-note', 'file-type-pdf', 'file-type-sheet', 'file-type-slide', 'file-type-text', 'file-type-video', 'file-type-zip', 'forbidden-sign', 'google', 'keychain', 'logout-large', 'papers', 'only-office', 'store', 'top-select', 'trash-duotone', 'cozy']
|
|
1022
1024
|
|
|
1023
1025
|
;
|
|
1024
1026
|
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
// Automatically created, please run `scripts/generate-svgr-icon.sh assets/icons/illus/only-office.svg` to regenerate;
|
|
2
|
+
import React from 'react'
|
|
3
|
+
|
|
4
|
+
function SvgOnlyOffice(props) {
|
|
5
|
+
return (
|
|
6
|
+
<svg viewBox="0 0 16 16" fill="none" {...props}>
|
|
7
|
+
<g
|
|
8
|
+
clipPath="url(#only-office_svg__clip0_6882_51948)"
|
|
9
|
+
fillRule="evenodd"
|
|
10
|
+
clipRule="evenodd"
|
|
11
|
+
>
|
|
12
|
+
<path
|
|
13
|
+
d="M7 15.172l-6.58-3.02c-.56-.264-.56-.672 0-.912l2.291-1.055 4.265 1.966c.56.264 1.463.264 1.999 0l4.265-1.966 2.29 1.055c.561.264.561.671 0 .911l-6.58 3.021c-.511.24-1.413.24-1.95 0z"
|
|
14
|
+
fill="url(#only-office_svg__paint0_linear_6882_51948)"
|
|
15
|
+
/>
|
|
16
|
+
<path
|
|
17
|
+
d="M7 11.456L.42 8.436c-.56-.265-.56-.672 0-.912l2.243-1.03L7 8.483c.56.263 1.462.263 1.998 0l4.338-1.99 2.242 1.03c.561.264.561.671 0 .911L9 11.456c-.56.264-1.462.264-1.998 0z"
|
|
18
|
+
fill="url(#only-office_svg__paint1_linear_6882_51948)"
|
|
19
|
+
/>
|
|
20
|
+
<path
|
|
21
|
+
d="M7 7.836L.42 4.815c-.56-.264-.56-.672 0-.911L7 .883c.561-.264 1.463-.264 2 0l6.58 3.02c.56.264.56.672 0 .912L9 7.835c-.561.24-1.463.24-2 0z"
|
|
22
|
+
fill="url(#only-office_svg__paint2_linear_6882_51948)"
|
|
23
|
+
/>
|
|
24
|
+
</g>
|
|
25
|
+
<defs>
|
|
26
|
+
<linearGradient
|
|
27
|
+
id="only-office_svg__paint0_linear_6882_51948"
|
|
28
|
+
x1={7.994}
|
|
29
|
+
y1={18.035}
|
|
30
|
+
x2={7.994}
|
|
31
|
+
y2={7.007}
|
|
32
|
+
gradientUnits="userSpaceOnUse"
|
|
33
|
+
>
|
|
34
|
+
<stop stopColor="#FCC2B1" />
|
|
35
|
+
<stop offset={0.885} stopColor="#D9420B" />
|
|
36
|
+
</linearGradient>
|
|
37
|
+
<linearGradient
|
|
38
|
+
id="only-office_svg__paint1_linear_6882_51948"
|
|
39
|
+
x1={7.994}
|
|
40
|
+
y1={13.26}
|
|
41
|
+
x2={7.994}
|
|
42
|
+
y2={6.007}
|
|
43
|
+
gradientUnits="userSpaceOnUse"
|
|
44
|
+
>
|
|
45
|
+
<stop stopColor="#DEEDC9" />
|
|
46
|
+
<stop offset={0.661} stopColor="#8BBA25" />
|
|
47
|
+
</linearGradient>
|
|
48
|
+
<linearGradient
|
|
49
|
+
id="only-office_svg__paint2_linear_6882_51948"
|
|
50
|
+
x1={7.994}
|
|
51
|
+
y1={10.323}
|
|
52
|
+
x2={7.994}
|
|
53
|
+
y2={0.453}
|
|
54
|
+
gradientUnits="userSpaceOnUse"
|
|
55
|
+
>
|
|
56
|
+
<stop stopColor="#C2EBFA" />
|
|
57
|
+
<stop offset={1} stopColor="#26A8DE" />
|
|
58
|
+
</linearGradient>
|
|
59
|
+
<clipPath id="only-office_svg__clip0_6882_51948">
|
|
60
|
+
<path
|
|
61
|
+
fill="#fff"
|
|
62
|
+
transform="translate(0 .556)"
|
|
63
|
+
d="M0 0h16v14.889H0z"
|
|
64
|
+
/>
|
|
65
|
+
</clipPath>
|
|
66
|
+
</defs>
|
|
67
|
+
</svg>
|
|
68
|
+
)
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
export default SvgOnlyOffice
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
```jsx
|
|
2
|
+
import QualificationIcon from 'cozy-ui/transpiled/react/QualificationIcon'
|
|
3
|
+
|
|
4
|
+
;
|
|
5
|
+
|
|
6
|
+
<>
|
|
7
|
+
<QualificationIcon className="u-mr-1" />
|
|
8
|
+
<QualificationIcon className="u-mr-1" qualification="isp_invoice" />
|
|
9
|
+
<QualificationIcon className="u-mr-1" qualification="phone_invoice" />
|
|
10
|
+
<QualificationIcon className="u-mr-1" qualification="family_record_book" />
|
|
11
|
+
<QualificationIcon className="u-mr-1" theme="identity" />
|
|
12
|
+
<QualificationIcon theme="transport" />
|
|
13
|
+
</>
|
|
14
|
+
```
|
|
@@ -4,7 +4,6 @@ import React from 'react'
|
|
|
4
4
|
import { getIconByLabel } from 'cozy-client/dist/models/document/qualification'
|
|
5
5
|
|
|
6
6
|
import Icon from '../Icon'
|
|
7
|
-
import IconStack from '../IconStack'
|
|
8
7
|
import BankIcon from '../Icons/Bank'
|
|
9
8
|
import BankCheckIcon from '../Icons/BankCheck'
|
|
10
9
|
import BenefitIcon from '../Icons/Benefit'
|
|
@@ -16,8 +15,6 @@ import DotsIcon from '../Icons/Dots'
|
|
|
16
15
|
import EmailIcon from '../Icons/Email'
|
|
17
16
|
import EuroIcon from '../Icons/Euro'
|
|
18
17
|
import ExchangeIcon from '../Icons/Exchange'
|
|
19
|
-
import FileDuotoneIcon from '../Icons/FileDuotone'
|
|
20
|
-
import FileTypeNoteIcon from '../Icons/FileTypeNote'
|
|
21
18
|
import FitnessIcon from '../Icons/Fitness'
|
|
22
19
|
import GlobeIcon from '../Icons/Globe'
|
|
23
20
|
import GouvIcon from '../Icons/Gouv'
|
|
@@ -27,6 +24,7 @@ import ImageIcon from '../Icons/Image'
|
|
|
27
24
|
import JusticeIcon from '../Icons/Justice'
|
|
28
25
|
import LaudryIcon from '../Icons/Laudry'
|
|
29
26
|
import LightningIcon from '../Icons/Lightning'
|
|
27
|
+
import NoteIcon from '../Icons/Note'
|
|
30
28
|
import PeopleIcon from '../Icons/People'
|
|
31
29
|
import PlaneIcon from '../Icons/Plane'
|
|
32
30
|
import RemboursementIcon from '../Icons/Remboursement'
|
|
@@ -39,20 +37,6 @@ import TelephoneIcon from '../Icons/Telephone'
|
|
|
39
37
|
import WaterIcon from '../Icons/Water'
|
|
40
38
|
import WorkIcon from '../Icons/Work'
|
|
41
39
|
|
|
42
|
-
// this is a copy of FileDuotone without the flap and with a white background
|
|
43
|
-
function FileDuotoneWhite(props) {
|
|
44
|
-
return (
|
|
45
|
-
<svg viewBox="0 0 26 32" {...props}>
|
|
46
|
-
<g fillRule="evenodd">
|
|
47
|
-
<path
|
|
48
|
-
d="M0 2.002C0 .896.89 0 1.997 0H19l7 7v22.996A2 2 0 0124.003 32H1.997A1.995 1.995 0 010 29.998C.048 16 0 16 0 2.002z"
|
|
49
|
-
fill="#ffffff"
|
|
50
|
-
/>
|
|
51
|
-
</g>
|
|
52
|
-
</svg>
|
|
53
|
-
)
|
|
54
|
-
}
|
|
55
|
-
|
|
56
40
|
const IconByLabel = {
|
|
57
41
|
'bank-check': BankCheckIcon,
|
|
58
42
|
bank: BankIcon,
|
|
@@ -65,7 +49,7 @@ const IconByLabel = {
|
|
|
65
49
|
email: EmailIcon,
|
|
66
50
|
euro: EuroIcon,
|
|
67
51
|
exchange: ExchangeIcon,
|
|
68
|
-
'file-type-note':
|
|
52
|
+
'file-type-note': NoteIcon,
|
|
69
53
|
fitness: FitnessIcon,
|
|
70
54
|
globe: GlobeIcon,
|
|
71
55
|
gouv: GouvIcon,
|
|
@@ -101,32 +85,21 @@ const themeIconByLabel = {
|
|
|
101
85
|
others: 'dots'
|
|
102
86
|
}
|
|
103
87
|
|
|
104
|
-
const
|
|
105
|
-
const
|
|
88
|
+
const QualificationIcon = ({ theme, qualification, ...props }) => {
|
|
89
|
+
const _Icon = qualification
|
|
106
90
|
? IconByLabel[getIconByLabel(qualification)]
|
|
107
91
|
: theme
|
|
108
92
|
? IconByLabel[themeIconByLabel[theme]]
|
|
109
93
|
: null
|
|
110
94
|
|
|
111
|
-
return
|
|
112
|
-
<IconStack
|
|
113
|
-
{...props}
|
|
114
|
-
backgroundIcon={
|
|
115
|
-
<>
|
|
116
|
-
<Icon className="u-pos-absolute" icon={FileDuotoneWhite} size={32} />
|
|
117
|
-
<Icon icon={FileDuotoneIcon} color="#E049BF" size={32} />
|
|
118
|
-
</>
|
|
119
|
-
}
|
|
120
|
-
foregroundIcon={<Icon icon={ForegroundIcon} color="#E049BF" size={16} />}
|
|
121
|
-
/>
|
|
122
|
-
)
|
|
95
|
+
return <Icon icon={_Icon} color="#E049BF" size={16} {...props} />
|
|
123
96
|
}
|
|
124
97
|
|
|
125
|
-
|
|
98
|
+
QualificationIcon.propTypes = {
|
|
126
99
|
/** The name of the qualification (isp\_invoice, family\_record\_book, etc.) */
|
|
127
100
|
qualification: PropTypes.string,
|
|
128
101
|
/** The name of the qualification theme (indentity, family, etc.) */
|
|
129
102
|
theme: PropTypes.string
|
|
130
103
|
}
|
|
131
104
|
|
|
132
|
-
export default
|
|
105
|
+
export default QualificationIcon
|
|
@@ -5,8 +5,8 @@ import { isQualificationNote } from 'cozy-client/dist/models/document/documentTy
|
|
|
5
5
|
import { getBoundT } from 'cozy-client/dist/models/document/locales'
|
|
6
6
|
|
|
7
7
|
import Icon from '../Icon'
|
|
8
|
-
import
|
|
9
|
-
import
|
|
8
|
+
import NoteIcon from '../Icons/Note'
|
|
9
|
+
import QualificationIcon from '../QualificationIcon'
|
|
10
10
|
|
|
11
11
|
export const makeOptions = lang => {
|
|
12
12
|
const qualifT = getBoundT(lang)
|
|
@@ -16,20 +16,20 @@ export const makeOptions = lang => {
|
|
|
16
16
|
{
|
|
17
17
|
id: 'none',
|
|
18
18
|
title: qualifT('Scan.themes.none'),
|
|
19
|
-
icon: <
|
|
19
|
+
icon: <QualificationIcon />
|
|
20
20
|
},
|
|
21
21
|
...themesList.map(theme => ({
|
|
22
22
|
id: theme.id,
|
|
23
23
|
title: qualifT(`Scan.themes.${theme.label}`),
|
|
24
|
-
icon: <
|
|
24
|
+
icon: <QualificationIcon theme={theme.label} />,
|
|
25
25
|
children: theme.items.map(item => ({
|
|
26
26
|
id: item.label,
|
|
27
27
|
item,
|
|
28
28
|
title: qualifT(`Scan.items.${item.label}`),
|
|
29
29
|
icon: isQualificationNote(item) ? (
|
|
30
|
-
<Icon icon={
|
|
30
|
+
<Icon icon={NoteIcon} color="#E049BF" size={16} />
|
|
31
31
|
) : (
|
|
32
|
-
<
|
|
32
|
+
<QualificationIcon qualification={item.label} />
|
|
33
33
|
)
|
|
34
34
|
}))
|
|
35
35
|
}))
|
package/react/index.js
CHANGED
|
@@ -125,7 +125,7 @@ export { default as Thumbnail } from './Thumbnail'
|
|
|
125
125
|
export { default as ButtonBase } from './ButtonBase'
|
|
126
126
|
export { default as QualificationGrid } from './QualificationGrid'
|
|
127
127
|
export { default as QualificationItem } from './QualificationItem'
|
|
128
|
-
export { default as
|
|
128
|
+
export { default as QualificationIcon } from './QualificationIcon'
|
|
129
129
|
export { default as QualificationModal } from './QualificationModal'
|
|
130
130
|
export { default as Timeline } from './Timeline'
|
|
131
131
|
export { default as TimelineConnector } from './TimelineConnector'
|