Skip to content

Commit

Permalink
Merge pull request #20 from MichalBryxi/fix/17/slider-looks-like-slider
Browse files Browse the repository at this point in the history
Fix/17/slider looks like slider
  • Loading branch information
MichalBryxi authored Dec 16, 2024
2 parents 19edf39 + d4b7e8f commit 0e13376
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 9 deletions.
2 changes: 2 additions & 0 deletions .prototools
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node = "22.11.0"
pnpm = "9.13.0"
18 changes: 10 additions & 8 deletions app/components/open-to/files/index.gjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,26 @@ import OpenToFilesPreview from 'open-to-dot-dot-dot/components/open-to/files/pre
import fileQueue from 'ember-file-upload/helpers/file-queue';
import OpenToFilesUpload from 'open-to-dot-dot-dot/components/open-to/files/upload';
import { t } from 'ember-intl';
import { notEq } from 'ember-truth-helpers';

export default class OpenToFiles extends Component {
<template>
{{#let (fileQueue onFileAdded=this.uploadPhoto) as |queue|}}
<ul role='list' class='grid grid-cols-1 gap-x-4 gap-y-8 sm:gap-x-6'>
<ul
role='list'
class='grid grid-cols-1 gap-x-4 gap-y-8 sm:gap-x-6
{{if (notEq queue.files.length 0) "sm:grid-cols-2"}}'
>
<li>
<OpenToFilesUpload />
</li>

{{#each queue.files as |file|}}
<li>
<div class='mx-auto w-full aspect-square relative'>
<OpenToFilesPreview @file={{file}} />
</div>
</li>
{{else}}
<li>
<div class='mx-auto w-full aspect-square relative'>
<OpenToFilesUpload />
</div>
</li>

{{/each}}
</ul>
{{/let}}
Expand Down
2 changes: 1 addition & 1 deletion translations/en-us.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ application:
name: '#OpenTo...'
subtitle: LinkedIn avatar generator
drag-and-drop:
instructions: Drop your image here
instructions: Drop your images here
drop-now: Drop it!
toggles:
text: Text
Expand Down

0 comments on commit 0e13376

Please sign in to comment.