Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Asset field loses upload text when 50% width on smaller viewports #11436

Closed
edalzell opened this issue Feb 7, 2025 · 4 comments · Fixed by #11459
Closed

Asset field loses upload text when 50% width on smaller viewports #11436

edalzell opened this issue Feb 7, 2025 · 4 comments · Fixed by #11459

Comments

@edalzell
Copy link
Contributor

edalzell commented Feb 7, 2025

Bug description

If you have an asset field that's 50% width and you make the viewport smaller you lose the "Upload file or drop..." text.

How to reproduce

  1. Add 2 asset fields side by side, each 50% width
  2. Decrease the window size

Image

Logs

Environment

Environment
Application Name: Statamic
Laravel Version: 11.41.3
PHP Version: 8.3.16
Composer Version: 2.8.4
Environment: local
Debug Mode: ENABLED
URL: asset-field.test
Maintenance Mode: OFF
Timezone: UTC
Locale: en

Cache
Config: NOT CACHED
Events: NOT CACHED
Routes: NOT CACHED
Views: CACHED

Drivers
Broadcasting: log
Cache: file
Database: sqlite
Logs: stack / single
Mail: log
Queue: sync
Session: file

Statamic
Addons: 0
Sites: 1
Stache Watcher: Enabled (auto)
Static Caching: Disabled
Version: 5.46.1 Solo

Installation

Fresh statamic/statamic site via CLI

Additional details

No response

@edalzell edalzell changed the title Asset field looses upload text when 50% width on smaller viewports Asset field loses upload text when 50% width on smaller viewports Feb 7, 2025
@jasonvarga
Copy link
Member

This looks intentional. When you get small enough, there's not enough space for all that text so it gets removed.

The functionality still works, there's just no helper text.

@edalzell
Copy link
Contributor Author

edalzell commented Feb 10, 2025

This looks intentional. When you get small enough, there's not enough space for all that text so it gets removed.

The functionality still works, there's just no helper text.

Functionality doesn't work though @jasonvarga, the users can't click Upload file to choose from their computer. On our site they're not allowed to Browse (so no button) so the field collapses to almost nothing. How are they supposed to get a file chooser?

How about we put less text at smaller viewports?

@edalzell edalzell reopened this Feb 10, 2025
@edalzell
Copy link
Contributor Author

For example @jasonvarga how is a use supposed to know they can drag and drop onto here? Or how do they get the upload file picker?

Image

And if you set permissions so folks can't choose existing assets, this is what you get:

Image

I suggest we use fewer words at smaller breakpoint and/or smaller font size

@jasonvarga
Copy link
Member

lol fair enough

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants