Move editor UI into the app and release verified Core dependencies (#14)
Gitea CI / Assemble and validate CI artifacts (push) Successful in 1m47s
Gitea CI / Check code and tests (push) Successful in 7m15s
Gitea CI / Build Android APK (push) Successful in 4m6s
Gitea CI / Build Windows x64 app (push) Successful in 3m34s
Gitea CI / Audit and package Windows x64 (push) Successful in 1m29s
Gitea CI / Gitea CI passed (push) Successful in 1s
Gitea Release / Prepare draft Release (push) Failing after 8s
Gitea Release / Upload Android to draft Release (push) Skipped
Gitea Release / Upload Windows to draft Release (push) Skipped
Gitea Release / Verify and publish Release (push) Skipped
Gitea CI / Assemble and validate CI artifacts (push) Successful in 1m47s
Gitea CI / Check code and tests (push) Successful in 7m15s
Gitea CI / Build Android APK (push) Successful in 4m6s
Gitea CI / Build Windows x64 app (push) Successful in 3m34s
Gitea CI / Audit and package Windows x64 (push) Successful in 1m29s
Gitea CI / Gitea CI passed (push) Successful in 1s
Gitea Release / Prepare draft Release (push) Failing after 8s
Gitea Release / Upload Android to draft Release (push) Skipped
Gitea Release / Upload Windows to draft Release (push) Skipped
Gitea Release / Verify and publish Release (push) Skipped
This commit was merged in pull request #14.
This commit is contained in:
1 parent
abc1868550
commit
06f1c26681
452 files changed
+43806
-2329
No files matched your search
@@ -292,6 +292,34 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
}
|
||||
|
||||
Widget _desktopToolbar(BuildContext context, RecentProject? selected) {
|
||||
final desktopButtonStyle = AppTheme.toolbarButtonStyle(context).copyWith(
|
||||
textStyle: WidgetStatePropertyAll(
|
||||
Theme.of(context).textTheme.bodyMedium!.copyWith(
|
||||
fontFamily: 'packages/cutdex_ui/Inter',
|
||||
fontSize: AppInspectorMetrics.fontSize,
|
||||
height: AppInspectorMetrics.lineHeight / AppInspectorMetrics.fontSize,
|
||||
fontWeight: FontWeight.w400,
|
||||
fontVariations: const [FontVariation('wght', 450)],
|
||||
letterSpacing: AppInspectorMetrics.fontSize * .005,
|
||||
),
|
||||
),
|
||||
minimumSize: const WidgetStatePropertyAll(
|
||||
Size(0, AppInspectorMetrics.input),
|
||||
),
|
||||
maximumSize: const WidgetStatePropertyAll(
|
||||
Size(double.infinity, AppInspectorMetrics.input),
|
||||
),
|
||||
padding: const WidgetStatePropertyAll(
|
||||
EdgeInsets.symmetric(horizontal: AppSpacing.small),
|
||||
),
|
||||
shape: const WidgetStatePropertyAll(
|
||||
RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.all(
|
||||
Radius.circular(AppInspectorMetrics.radius),
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
Widget category() => Semantics(
|
||||
label: context.l10n.mediaCategory,
|
||||
child: AppDropdownMenu(
|
||||
@@ -309,6 +337,7 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
buttonKey: const Key('media-category-button'),
|
||||
focusNode: focus,
|
||||
onPressed: toggle,
|
||||
style: desktopButtonStyle,
|
||||
child: Row(
|
||||
children: [
|
||||
Expanded(
|
||||
@@ -341,9 +370,14 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
else
|
||||
SizedBox(
|
||||
key: const Key('media-project-row'),
|
||||
height: 36,
|
||||
height: AppInspectorMetrics.row,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 4),
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
AppInspectorMetrics.padding,
|
||||
AppInspectorMetrics.rowPadding,
|
||||
AppInspectorMetrics.trailingPadding,
|
||||
AppInspectorMetrics.rowPadding,
|
||||
),
|
||||
child: LayoutBuilder(
|
||||
builder: (context, constraints) => Row(
|
||||
children: [
|
||||
@@ -369,6 +403,7 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
buttonKey: const Key('media-project-button'),
|
||||
focusNode: focusNode,
|
||||
onPressed: toggle,
|
||||
style: desktopButtonStyle,
|
||||
child: Row(
|
||||
children: [
|
||||
Expanded(
|
||||
@@ -385,7 +420,7 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
),
|
||||
),
|
||||
),
|
||||
const SizedBox(width: 4),
|
||||
const SizedBox(width: AppSpacing.small),
|
||||
ConstrainedBox(
|
||||
constraints: BoxConstraints(
|
||||
maxWidth: (constraints.maxWidth * .45).clamp(
|
||||
@@ -394,12 +429,12 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
),
|
||||
),
|
||||
child: SizedBox(
|
||||
height: 28,
|
||||
height: AppInspectorMetrics.input,
|
||||
child: Tooltip(
|
||||
message: context.l10n.importMedia,
|
||||
child: TextButton(
|
||||
key: const Key('media-import-button'),
|
||||
style: AppTheme.toolbarButtonStyle(context),
|
||||
style: desktopButtonStyle,
|
||||
onPressed: canImport ? onImport : null,
|
||||
child: Text(
|
||||
context.l10n.importMedia,
|
||||
@@ -427,6 +462,14 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
Widget Function() category,
|
||||
String Function(MediaSort) sortLabel,
|
||||
) {
|
||||
final searchText = Theme.of(context).textTheme.bodyMedium?.copyWith(
|
||||
fontFamily: 'packages/cutdex_ui/Inter',
|
||||
fontSize: AppInspectorMetrics.fontSize,
|
||||
height: AppInspectorMetrics.lineHeight / AppInspectorMetrics.fontSize,
|
||||
fontVariations: const [FontVariation('wght', 450)],
|
||||
letterSpacing: AppInspectorMetrics.fontSize * .005,
|
||||
);
|
||||
final colors = Theme.of(context).colorScheme;
|
||||
List<Widget> sortItems() => [
|
||||
for (final value in MediaSort.values)
|
||||
AppMenuItem(
|
||||
@@ -462,7 +505,7 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
required IconData icon,
|
||||
required List<Widget> items,
|
||||
}) => SizedBox.square(
|
||||
dimension: 28,
|
||||
dimension: AppInspectorMetrics.action,
|
||||
child: AppDropdownMenu(
|
||||
items: items,
|
||||
builder: (context, toggle, focus) => IconButton(
|
||||
@@ -477,9 +520,14 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
);
|
||||
return SizedBox(
|
||||
key: const Key('media-filter-row'),
|
||||
height: 40,
|
||||
height: AppInspectorMetrics.row,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.fromLTRB(12, 4, 12, 4),
|
||||
padding: const EdgeInsets.fromLTRB(
|
||||
AppInspectorMetrics.padding,
|
||||
AppInspectorMetrics.rowPadding,
|
||||
AppInspectorMetrics.trailingPadding,
|
||||
AppInspectorMetrics.rowPadding,
|
||||
),
|
||||
child: LayoutBuilder(
|
||||
builder: (context, constraints) {
|
||||
final wide = constraints.maxWidth >= 400;
|
||||
@@ -490,13 +538,10 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
key: const Key('media-search'),
|
||||
controller: _search,
|
||||
enabled: widget.onQueryChanged != null,
|
||||
style: AppTheme.inputTextStyle(
|
||||
context,
|
||||
style: AppTheme.toolbarTextStyle(context),
|
||||
),
|
||||
style: AppTheme.inputTextStyle(context, style: searchText),
|
||||
cursorHeight: AppTheme.inputCursorHeight(
|
||||
context,
|
||||
style: AppTheme.toolbarTextStyle(context),
|
||||
style: searchText,
|
||||
),
|
||||
textAlignVertical: TextAlignVertical.center,
|
||||
decoration: InputDecoration(
|
||||
@@ -505,36 +550,61 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
),
|
||||
hintStyle: AppTheme.inputHintStyle(
|
||||
context,
|
||||
style: AppTheme.toolbarTextStyle(context),
|
||||
style: searchText,
|
||||
),
|
||||
filled: true,
|
||||
fillColor: colors.surfaceContainer,
|
||||
isDense: true,
|
||||
constraints: const BoxConstraints(minHeight: 32),
|
||||
constraints: const BoxConstraints(
|
||||
minHeight: AppInspectorMetrics.input,
|
||||
),
|
||||
contentPadding: const EdgeInsets.symmetric(
|
||||
horizontal: 8,
|
||||
vertical: 4,
|
||||
horizontal: AppSpacing.small,
|
||||
),
|
||||
border: const OutlineInputBorder(
|
||||
borderRadius: BorderRadius.all(
|
||||
Radius.circular(AppInspectorMetrics.radius),
|
||||
),
|
||||
borderSide: BorderSide.none,
|
||||
),
|
||||
enabledBorder: const OutlineInputBorder(
|
||||
borderRadius: BorderRadius.all(
|
||||
Radius.circular(AppInspectorMetrics.radius),
|
||||
),
|
||||
borderSide: BorderSide.none,
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderRadius: const BorderRadius.all(
|
||||
Radius.circular(AppInspectorMetrics.radius),
|
||||
),
|
||||
borderSide: BorderSide(color: colors.primary),
|
||||
),
|
||||
prefixIcon: constraints.maxWidth < 160
|
||||
? null
|
||||
: const Icon(AppIcons.search, size: 16),
|
||||
prefixIconConstraints: const BoxConstraints(
|
||||
minWidth: 28,
|
||||
minHeight: 28,
|
||||
minWidth: AppInspectorMetrics.input,
|
||||
minHeight: AppInspectorMetrics.input,
|
||||
),
|
||||
),
|
||||
onChanged: (value) => widget.onQueryChanged?.call(value),
|
||||
),
|
||||
),
|
||||
const SizedBox(width: 4),
|
||||
const SizedBox(width: AppSpacing.small),
|
||||
if (wide) ...[
|
||||
SizedBox(width: 88, height: 28, child: category()),
|
||||
const SizedBox(width: 4),
|
||||
SizedBox(
|
||||
width: 88,
|
||||
height: AppInspectorMetrics.input,
|
||||
child: category(),
|
||||
),
|
||||
const SizedBox(width: AppSpacing.small),
|
||||
menuButton(
|
||||
key: const Key('media-sort-button'),
|
||||
tooltip: context.l10n.sortMedia,
|
||||
icon: AppIcons.sort,
|
||||
items: sortItems(),
|
||||
),
|
||||
const SizedBox(width: 4),
|
||||
const SizedBox(width: AppSpacing.small),
|
||||
menuButton(
|
||||
key: const Key('media-size-button'),
|
||||
tooltip: context.l10n.mediaThumbnailSize,
|
||||
@@ -564,9 +634,9 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
...sizeItems(),
|
||||
],
|
||||
),
|
||||
const SizedBox(width: 4),
|
||||
const SizedBox(width: AppSpacing.small),
|
||||
SizedBox.square(
|
||||
dimension: 28,
|
||||
dimension: AppInspectorMetrics.action,
|
||||
child: IconButton(
|
||||
key: const Key('media-layout-toggle'),
|
||||
onPressed: onToggleGrid,
|
||||
@@ -581,9 +651,9 @@ class _MediaBrowserToolbarState extends State<MediaBrowserToolbar> {
|
||||
),
|
||||
),
|
||||
if (widget.projectScoped) ...[
|
||||
const SizedBox(width: 4),
|
||||
const SizedBox(width: AppSpacing.small),
|
||||
SizedBox.square(
|
||||
dimension: 28,
|
||||
dimension: AppInspectorMetrics.action,
|
||||
child: IconButton(
|
||||
key: const Key('media-import-button'),
|
||||
onPressed: canImport ? () => onImport() : null,
|
||||
|
||||
Reference in new issue
Block a user