mirror of
https://github.com/AppFlowy-IO/AppFlowy.git
synced 2024-08-30 18:12:39 +00:00
chore: adjust legacy space icon (#5886)
This commit is contained in:
parent
aab942d163
commit
41a346c7ed
@ -500,7 +500,7 @@ class CurrentSpace extends StatelessWidget {
|
||||
SpaceIcon(
|
||||
dimension: 22,
|
||||
space: space,
|
||||
svgSize: 13,
|
||||
svgSize: 12,
|
||||
cornerRadius: 8.0,
|
||||
),
|
||||
const HSpace(10),
|
||||
|
@ -39,9 +39,10 @@ class SpaceIcon extends StatelessWidget {
|
||||
height: dimension,
|
||||
color: color,
|
||||
child: Center(
|
||||
child: svgSize == null
|
||||
? svg
|
||||
: SizedBox.square(dimension: svgSize!, child: svg),
|
||||
child:
|
||||
svgSize == null || space.spaceIcon?.contains('space_icon') == true
|
||||
? svg
|
||||
: SizedBox.square(dimension: svgSize!, child: svg),
|
||||
),
|
||||
),
|
||||
);
|
||||
|
@ -119,6 +119,20 @@ class _SpaceIconPopupState extends State<SpaceIconPopup> {
|
||||
dimension: 32,
|
||||
iconDimension: 32,
|
||||
);
|
||||
} else if (value.contains('space_icon')) {
|
||||
child = ClipRRect(
|
||||
borderRadius: BorderRadius.circular(widget.cornerRadius),
|
||||
child: Container(
|
||||
color: Color(int.parse(color)),
|
||||
child: Align(
|
||||
child: FlowySvg(
|
||||
FlowySvgData('assets/flowy_icons/16x/$value.svg'),
|
||||
size: const Size.square(42),
|
||||
color: Theme.of(context).colorScheme.surface,
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
} else {
|
||||
final content = kIconGroups?.findSvgContent(value);
|
||||
if (content == null) {
|
||||
|
Loading…
Reference in New Issue
Block a user