-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: wrap ancestors + preview via tooltip, switch to super_context_menu
- Loading branch information
1 parent
54fe38d
commit 6c98aa1
Showing
13 changed files
with
210 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1,48 @@ | ||
import 'package:pret_a_porter/pret_a_porter.dart'; | ||
import 'package:super_context_menu/super_context_menu.dart' as scm; | ||
|
||
import 'export_utils.dart'; | ||
import 'model/entry_data.dart'; | ||
import 'model/tag_data.dart'; | ||
|
||
Menu buildTagButtonContextMenu( | ||
scm.Menu buildTagButtonContextMenu( | ||
String tagName, | ||
PeregrineTag tagInfo, | ||
Function(String) autoEncryptToggleCallback, | ||
List<PeregrineEntry> entries, | ||
) => | ||
Menu( | ||
items: [ | ||
MenuItem.checkbox( | ||
label: 'Auto Encrypt', | ||
checked: tagInfo.autoEncrypt, | ||
onClick: (_) => autoEncryptToggleCallback(tagName), | ||
scm.Menu( | ||
children: [ | ||
scm.MenuAction( | ||
title: 'Auto Encrypt', | ||
state: tagInfo.autoEncrypt | ||
? scm.MenuActionState.checkOn | ||
: scm.MenuActionState.checkOff, | ||
callback: () => autoEncryptToggleCallback(tagName), | ||
), | ||
MenuItem.submenu( | ||
label: 'Export as...', | ||
submenu: Menu( | ||
items: [ | ||
MenuItem( | ||
label: 'Markdown', | ||
onClick: (_) => exportMarkdown( | ||
entries: entries, | ||
logName: tagName, | ||
), | ||
scm.Menu( | ||
title: 'Export as...', | ||
children: [ | ||
scm.MenuAction( | ||
title: 'Markdown', | ||
callback: () => exportMarkdown( | ||
entries: entries, | ||
logName: tagName, | ||
), | ||
], | ||
), | ||
) | ||
), | ||
], | ||
), | ||
], | ||
); | ||
|
||
Menu buildEntryCardContextMenu({ | ||
scm.Menu buildEntryCardContextMenu({ | ||
required String entryId, | ||
required Function(String) addAncestorCallback, | ||
}) => | ||
Menu( | ||
items: [ | ||
MenuItem( | ||
label: 'Add as ancestor', | ||
onClick: (_) => addAncestorCallback(entryId), | ||
scm.Menu( | ||
children: [ | ||
scm.MenuAction( | ||
title: 'Add as ancestor', | ||
callback: () => addAncestorCallback(entryId), | ||
) | ||
], | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,53 @@ | ||
PODS: | ||
- contextual_menu (0.0.1): | ||
- FlutterMacOS | ||
- device_info_plus (0.0.1): | ||
- FlutterMacOS | ||
- FlutterMacOS (1.0.0) | ||
- irondash_engine_context (0.0.1): | ||
- FlutterMacOS | ||
- path_provider_foundation (0.0.1): | ||
- Flutter | ||
- FlutterMacOS | ||
- super_native_extensions (0.0.1): | ||
- FlutterMacOS | ||
- url_launcher_macos (0.0.1): | ||
- FlutterMacOS | ||
|
||
DEPENDENCIES: | ||
- contextual_menu (from `Flutter/ephemeral/.symlinks/plugins/contextual_menu/macos`) | ||
- device_info_plus (from `Flutter/ephemeral/.symlinks/plugins/device_info_plus/macos`) | ||
- FlutterMacOS (from `Flutter/ephemeral`) | ||
- irondash_engine_context (from `Flutter/ephemeral/.symlinks/plugins/irondash_engine_context/macos`) | ||
- path_provider_foundation (from `Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin`) | ||
- super_native_extensions (from `Flutter/ephemeral/.symlinks/plugins/super_native_extensions/macos`) | ||
- url_launcher_macos (from `Flutter/ephemeral/.symlinks/plugins/url_launcher_macos/macos`) | ||
|
||
EXTERNAL SOURCES: | ||
contextual_menu: | ||
:path: Flutter/ephemeral/.symlinks/plugins/contextual_menu/macos | ||
device_info_plus: | ||
:path: Flutter/ephemeral/.symlinks/plugins/device_info_plus/macos | ||
FlutterMacOS: | ||
:path: Flutter/ephemeral | ||
irondash_engine_context: | ||
:path: Flutter/ephemeral/.symlinks/plugins/irondash_engine_context/macos | ||
path_provider_foundation: | ||
:path: Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin | ||
super_native_extensions: | ||
:path: Flutter/ephemeral/.symlinks/plugins/super_native_extensions/macos | ||
url_launcher_macos: | ||
:path: Flutter/ephemeral/.symlinks/plugins/url_launcher_macos/macos | ||
|
||
SPEC CHECKSUMS: | ||
contextual_menu: 6d35fb15942c0d8769f5eae8d3bda653994a6f5a | ||
device_info_plus: ce1b7762849d3ec103d0e0517299f2db7ad60720 | ||
FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24 | ||
irondash_engine_context: da62996ee25616d2f01bbeb85dc115d813359478 | ||
path_provider_foundation: 29f094ae23ebbca9d3d0cec13889cd9060c0e943 | ||
super_native_extensions: 85efee3a7495b46b04befcfc86ed12069264ebf3 | ||
url_launcher_macos: d2691c7dd33ed713bf3544850a623080ec693d95 | ||
|
||
PODFILE CHECKSUM: 236401fc2c932af29a9fcf0e97baeeb2d750d367 | ||
|
||
COCOAPODS: 1.13.0 | ||
COCOAPODS: 1.15.2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.