diff --git a/assets/fonts/ArDriveIcons.ttf b/assets/fonts/ArDriveIcons.ttf index 77aabb0..b141e1d 100644 Binary files a/assets/fonts/ArDriveIcons.ttf and b/assets/fonts/ArDriveIcons.ttf differ diff --git a/assets/fonts/config.json b/assets/fonts/config.json index 9ee1628..eba0f4e 100644 --- a/assets/fonts/config.json +++ b/assets/fonts/config.json @@ -636,20 +636,6 @@ "minus-rectangle" ] }, - { - "uid": "641cee69d0ab8673d1185dfd2a425995", - "css": "move", - "code": 59439, - "src": "custom_icons", - "selected": true, - "svg": { - "path": "M664 83H667 668Q684 83 696 95L905 304Q917 316 917 333V792Q917 825 900 854T855 900 792 917H563Q545 917 533 905T521 875 533 845 563 833H792Q809 833 821 821T833 792V375H708Q674 375 650 350T625 292V167H375Q358 167 346 179T334 208V542Q334 559 322 571T292 583 263 571 250 542V208Q250 174 267 145T313 100 375 83H664ZM775 292L708 225V292H775ZM304 946Q316 958 334 958H333Q348 958 362 946L487 821Q493 815 496 807T499 791H500L499 787Q498 779 496 775 493 767 488 762L363 637Q350 624 333 624T304 636 291 666 304 696L358 749H167Q149 749 137 761T125 791 137 820 167 833H358L304 887Q291 899 291 917T304 946Z", - "width": 1000 - }, - "search": [ - "move" - ] - }, { "uid": "55cb30fbbeea922b15cc16da5845cc29", "css": "music", @@ -901,6 +887,48 @@ "search": [ "detach" ] + }, + { + "uid": "641cee69d0ab8673d1185dfd2a425995", + "css": "move", + "code": 59439, + "src": "custom_icons", + "selected": true, + "svg": { + "path": "M664 83H667 668Q684 83 696 95L905 304Q917 316 917 333V792Q917 825 900 854T855 900 792 917H563Q545 917 533 905T521 875 533 845 563 833H792Q809 833 821 821T833 792V375H708Q674 375 650 350T625 292V167H375Q358 167 346 179T334 208V542Q334 559 322 571T292 583 263 571 250 542V208Q250 174 267 145T313 100 375 83H664ZM775 292L708 225V292H775ZM304 946Q316 958 334 958H333Q348 958 362 946L487 821Q493 815 496 807T499 791H500L499 787Q498 779 496 775 493 767 488 762L363 637Q350 624 333 624T304 636 291 666 304 696L358 749H167Q149 749 137 761T125 791 137 820 167 833H358L304 887Q291 899 291 917T304 946Z", + "width": 1000 + }, + "search": [ + "move" + ] + }, + { + "uid": "c8ec8e47d37ffab6c94eb5cd1a22d23c", + "css": "manifest-icon-flattened", + "code": 59457, + "src": "custom_icons", + "selected": true, + "svg": { + "path": "M533.3 166.7C588.6 166.7 633.3 211.4 633.3 266.7V333.3C633.3 388.5 588.6 433.3 533.3 433.3V466.7H633.3C686.6 466.7 730.1 508.3 733.2 560.8L733.3 566.7C788.6 566.7 833.3 611.4 833.3 666.7V733.3C833.3 788.5 788.6 833.3 733.3 833.3H666.7C611.5 833.3 566.7 788.5 566.7 733.3V666.7C566.7 611.4 611.5 566.7 666.7 566.7 666.7 549.6 653.8 535.5 637.3 533.6L366.7 533.3C349.6 533.3 335.5 546.2 333.6 562.8L333.4 566.7C388.6 566.7 433.4 611.4 433.4 666.7V733.3C433.4 788.5 388.6 833.3 333.4 833.3H266.7C211.5 833.3 166.7 788.5 166.7 733.3V666.7C166.7 611.4 211.5 566.7 266.7 566.7 266.7 513.4 308.3 469.9 360.8 466.8L366.7 466.7H466.7V433.3C411.5 433.3 366.7 388.5 366.7 333.3V266.7C366.7 211.4 411.5 166.7 466.7 166.7H533.4ZM533.3 366.7C551.8 366.7 566.7 351.7 566.7 333.3V266.7C566.7 248.3 551.8 233.3 533.3 233.3H466.7C448.3 233.3 433.3 248.3 433.3 266.7V333.3C433.3 351.7 448.3 366.7 466.7 366.7H533.3ZM666.7 633.3C648.3 633.3 633.3 648.3 633.3 666.7V733.3C633.3 751.7 648.3 766.7 666.7 766.7H733.3C751.7 766.7 766.7 751.7 766.7 733.3V666.7C766.7 648.3 751.7 633.3 733.3 633.3H666.7ZM333.3 633.3H266.7C248.3 633.3 233.3 648.3 233.3 666.7V733.3C233.3 751.7 248.3 766.7 266.7 766.7H333.3C351.7 766.7 366.7 751.7 366.7 733.3V666.7C366.7 648.3 351.7 633.3 333.3 633.3Z", + "width": 1000 + }, + "search": [ + "manifest-icon-flattened" + ] + }, + { + "uid": "40b2b20d850dd1a256f11bdb905695c4", + "css": "download-2", + "code": 59458, + "src": "custom_icons", + "selected": true, + "svg": { + "path": "M411.9 533C411.8 531.8 411.8 530.6 411.8 529.4V58.8C411.8 26.3 438.1 0 470.6 0 503.1 0 529.4 26.3 529.4 58.8V529.4C529.4 529.6 529.4 529.7 529.4 529.9L670.7 423.5C696.7 404 733.5 409.3 753 435.3 772.5 461.3 767.3 498.2 741.3 517.7L506 694.1C495.8 701.8 483.4 705.9 470.7 705.9 458.5 706 446.6 702.3 436.6 695.3L201.3 529.4C174.9 510.7 168.6 474.1 187.1 447.7 205.8 421 242.5 414.6 269.1 433.2L269.5 433.5 411.9 533ZM0 823.5V941.2C0 973.7 26.3 1000 58.8 1000H882.4C914.8 1000 941.2 973.7 941.2 941.2V823.5C941.2 791 914.8 764.7 882.4 764.7 849.9 764.7 823.5 791 823.5 823.5V882.4H117.6V823.5C117.6 791 91.3 764.7 58.8 764.7 26.3 764.7 0 791 0 823.5Z", + "width": 941 + }, + "search": [ + "style-6" + ] } ] } \ No newline at end of file diff --git a/lib/src/styles/icons/ar_drive_icons_icons.dart b/lib/src/styles/icons/ar_drive_icons_icons.dart index 3b1946c..f1183ff 100644 --- a/lib/src/styles/icons/ar_drive_icons_icons.dart +++ b/lib/src/styles/icons/ar_drive_icons_icons.dart @@ -145,6 +145,10 @@ class ArDriveIconsData { IconData(0xe83d, fontFamily: _kFontFam, fontPackage: _kFontPkg); static const IconData detach = IconData(0xe83f, fontFamily: _kFontFam, fontPackage: _kFontPkg); + static const IconData manifest_icon_flattened = + IconData(0xe841, fontFamily: _kFontFam, fontPackage: _kFontPkg); + static const IconData download_2 = + IconData(0xe842, fontFamily: _kFontFam, fontPackage: _kFontPkg); static const IconData pin_circle = IconData(0xe844, fontFamily: _kFontFam, fontPackage: _kFontPkg); static const IconData pin_no_circle = diff --git a/lib/src/styles/icons/icons.dart b/lib/src/styles/icons/icons.dart index 2b1b0a7..4a371da 100644 --- a/lib/src/styles/icons/icons.dart +++ b/lib/src/styles/icons/icons.dart @@ -433,4 +433,16 @@ class ArDriveIcons { size: size, color: color, ); + + static ArDriveIcon download2({double? size, Color? color}) => ArDriveIcon( + icon: ArDriveIconsData.download_2, + size: size ?? 18, + color: color, + ); + + static ArDriveIcon manifest({double? size, Color? color}) => ArDriveIcon( + icon: ArDriveIconsData.manifest_icon_flattened, + size: size ?? 26, + color: color, + ); } diff --git a/pubspec.yaml b/pubspec.yaml index 84aa0b1..67a74e7 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,7 +1,7 @@ name: ardrive_ui description: UI Design Library for the ArDrive Design System -version: 1.14.0 +version: 1.15.0 publish_to: "none" @@ -13,7 +13,7 @@ dependencies: ardrive_io: git: url: https://github.com/ar-io/ardrive_io.git - ref: PE-4923 + ref: v1.4.2 auto_size_text: ^3.0.0 desktop_drop: ^0.4.0 dotted_border: ^2.0.0+3 diff --git a/storybook/lib/src/icons.dart b/storybook/lib/src/icons.dart new file mode 100644 index 0000000..46fe657 --- /dev/null +++ b/storybook/lib/src/icons.dart @@ -0,0 +1,112 @@ +import 'package:ardrive_ui/ardrive_ui.dart'; +import 'package:flutter/material.dart'; +import 'package:storybook/src/ardrive_app_base.dart'; +import 'package:widgetbook/widgetbook.dart'; + +WidgetbookCategory icons() { + return WidgetbookCategory( + name: 'Icons', + children: [ + WidgetbookComponent( + name: 'Icons', + useCases: [ + WidgetbookUseCase( + name: 'Icons', + builder: (context) { + return ArDriveStorybookAppBase(builder: (context) { + return ListView.builder( + itemCount: _options.length, + itemBuilder: (context, index) { + return ListTile( + leading: _options[index].icon, + title: Text(_options[index].name, + style: ArDriveTypography.body.buttonNormalBold()), + ); + }, + ); + }); + }, + ), + ], + ), + ], + ); +} + +// TODO: we may want to generate this list from the icons.dart file +List _options = [ + IconOption(icon: ArDriveIcons.iconAddDrive(), name: 'iconAddDrive'), + IconOption(icon: ArDriveIcons.iconNewFolder1(), name: 'iconNewFolder1'), + IconOption(icon: ArDriveIcons.iconUploadFolder1(), name: 'iconUploadFolder1'), + IconOption(icon: ArDriveIcons.iconUploadFiles(), name: 'iconUploadFiles'), + IconOption( + icon: ArDriveIcons.iconCreateSnapshot(), name: 'iconCreateSnapshot'), + IconOption(icon: ArDriveIcons.iconAttachDrive(), name: 'iconAttachDrive'), + IconOption(icon: ArDriveIcons.arconnectIcon1(), name: 'arconnectIcon1'), + IconOption(icon: ArDriveIcons.addDrive(), name: 'addDrive'), + IconOption(icon: ArDriveIcons.arrowLeftFilled(), name: 'arrowLeftFilled'), + IconOption(icon: ArDriveIcons.arrowLeftOutline(), name: 'arrowLeftOutline'), + IconOption(icon: ArDriveIcons.arrowLeft(), name: 'arrowLeft'), + IconOption(icon: ArDriveIcons.arrowRightFilled(), name: 'arrowRightFilled'), + IconOption(icon: ArDriveIcons.arrowRightOutline(), name: 'arrowRightOutline'), + IconOption(icon: ArDriveIcons.bullertList(), name: 'bullertList'), + IconOption(icon: ArDriveIcons.camera1(), name: 'camera1'), + IconOption(icon: ArDriveIcons.camera2(), name: 'camera2'), + IconOption(icon: ArDriveIcons.carretDown(), name: 'carretDown'), + IconOption(icon: ArDriveIcons.carretLeft(), name: 'carretLeft'), + IconOption(icon: ArDriveIcons.carretRight(), name: 'carretRight'), + IconOption(icon: ArDriveIcons.carretUp(), name: 'carretUp'), + IconOption(icon: ArDriveIcons.checkCirle(), name: 'checkCirle'), + IconOption(icon: ArDriveIcons.checkmark(), name: 'checkmark'), + IconOption(icon: ArDriveIcons.closeCircle(), name: 'closeCircle'), + IconOption(icon: ArDriveIcons.closeRectangle(), name: 'closeRectangle'), + IconOption(icon: ArDriveIcons.copy(), name: 'copy'), + IconOption(icon: ArDriveIcons.dots(), name: 'dots'), + IconOption(icon: ArDriveIcons.download(), name: 'download'), + IconOption(icon: ArDriveIcons.editFilled(), name: 'editFilled'), + IconOption(icon: ArDriveIcons.edit(), name: 'edit'), + IconOption(icon: ArDriveIcons.fileX(), name: 'fileX'), + IconOption(icon: ArDriveIcons.file(), name: 'file'), + IconOption(icon: ArDriveIcons.fileOutlined(), name: 'fileOutlined'), + IconOption(icon: ArDriveIcons.folderFilled(), name: 'folderFilled'), + IconOption(icon: ArDriveIcons.folderOutline(), name: 'folderOutline'), + IconOption(icon: ArDriveIcons.upload(), name: 'upload'), + IconOption(icon: ArDriveIcons.triangle(), name: 'triangle'), + IconOption(icon: ArDriveIcons.menu(), name: 'menu'), + IconOption(icon: ArDriveIcons.refresh(), name: 'refresh'), + IconOption(icon: ArDriveIcons.x(), name: 'x'), + IconOption(icon: ArDriveIcons.newWindow(), name: 'newWindow'), + IconOption(icon: ArDriveIcons.share(), name: 'share'), + IconOption(icon: ArDriveIcons.move(), name: 'move'), + IconOption(icon: ArDriveIcons.plus(), name: 'plus'), + IconOption(icon: ArDriveIcons.tournament(), name: 'tournament'), + IconOption(icon: ArDriveIcons.logout(), name: 'logout'), + IconOption(icon: ArDriveIcons.user(), name: 'user'), + IconOption(icon: ArDriveIcons.zip(), name: 'zip'), + IconOption(icon: ArDriveIcons.question(), name: 'question'), + IconOption(icon: ArDriveIcons.image(), name: 'image'), + IconOption(icon: ArDriveIcons.video(), name: 'video'), + IconOption(icon: ArDriveIcons.music(), name: 'music'), + IconOption(icon: ArDriveIcons.info(), name: 'info'), + IconOption(icon: ArDriveIcons.kebabMenu(), name: 'kebabMenu'), + IconOption(icon: ArDriveIcons.eyeClosed(), name: 'eyeClosed'), + IconOption(icon: ArDriveIcons.eyeOpen(), name: 'eyeOpen'), + IconOption(icon: ArDriveIcons.keypad(), name: 'keypad'), + IconOption(icon: ArDriveIcons.pinNoCircle(), name: 'pinNoCircle'), + IconOption(icon: ArDriveIcons.pinWithCircle(), name: 'pinWithCircle'), + IconOption(icon: ArDriveIcons.arrowDownload(), name: 'arrowDownload'), + IconOption(icon: ArDriveIcons.cloudSync(), name: 'cloudSync'), + IconOption(icon: ArDriveIcons.detach(), name: 'detach'), + IconOption(icon: ArDriveIcons.download2(), name: 'download2'), + IconOption(icon: ArDriveIcons.manifest(), name: 'manifest'), +]; + +class IconOption { + final ArDriveIcon icon; + final String name; + + const IconOption({ + required this.icon, + required this.name, + }); +} diff --git a/storybook/lib/src/story_book.dart b/storybook/lib/src/story_book.dart index bc3e507..84c69f0 100644 --- a/storybook/lib/src/story_book.dart +++ b/storybook/lib/src/story_book.dart @@ -8,6 +8,7 @@ import 'package:storybook/src/colors.dart'; import 'package:storybook/src/drop_area.dart'; import 'package:storybook/src/fab.dart'; import 'package:storybook/src/feedback_message.dart'; +import 'package:storybook/src/icons.dart'; import 'package:storybook/src/image.dart'; import 'package:storybook/src/modals.dart'; import 'package:storybook/src/overlay.dart'; @@ -59,6 +60,7 @@ class StoryBook extends StatelessWidget { fab(), clickArea(), feedbackMessage(), + icons(), ], ) ], diff --git a/storybook/pubspec.lock b/storybook/pubspec.lock index 268bf86..934a4aa 100644 --- a/storybook/pubspec.lock +++ b/storybook/pubspec.lock @@ -5,8 +5,8 @@ packages: dependency: transitive description: path: "." - ref: PE-4896-drag-and-drop-applies-wrong-content-type-to-files - resolved-ref: "19616c9d8490db3a09b23292f36ee6480b7b7dc3" + ref: "v1.4.1" + resolved-ref: "441c37764a1b120057ec2cd1e6eecb47bb35a37a" url: "https://github.com/ar-io/ardrive_io.git" source: git version: "1.4.1" @@ -16,7 +16,7 @@ packages: path: ".." relative: true source: path - version: "1.13.1" + version: "1.14.0" args: dependency: transitive description: