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

Replace size tag with scale #249

Open
bruvellu opened this issue Nov 12, 2023 · 3 comments
Open

Replace size tag with scale #249

bruvellu opened this issue Nov 12, 2023 · 3 comments
Assignees
Labels
improvement Issues with improvements for existing features

Comments

@bruvellu
Copy link
Owner

Describe what's not optimal
Size is a generic name that can be mistaken for file size (MB) or image resolution (2000px).

Describe what could be done to improve (optional)
Change all instances of size for scale.

@bruvellu bruvellu added the improvement Issues with improvements for existing features label Nov 12, 2023
@bruvellu
Copy link
Owner Author

I started creating a Scale model, but that felt like an overkill for this feature. For now, I'll make scale be a field of Media with the choices described in this comment.

That means, I'll remove the Size tag category and its descriptions. Here they are for the record:

<0,1 mm / <0.1 mm / micro / Organismos unicelulares e detalhes de organismos multicelulares. / Unicellular organisms and details of multicellular organisms.
0,1 - 1,0 mm / 0.1 - 1.0 mm / tiny / Embriões, larvas e seres planctônicos. / Embryos, larvae and planktonic creatures.
1,0 - 10 mm / 1.0 - 10 mm / visible / Seres diminutos, mas visíveis a olho nu. / Tiny creatures but visible at the naked eye.
10 - 100 mm / 10 - 100 mm / large / Organismos macroscópicos. / Macroscopic organisms.
>100 mm / >100 mm / huge / Organismos ainda maiores. / Even larger organisms.

@bruvellu
Copy link
Owner Author

bruvellu commented Nov 26, 2023

Applied changes in 4f14e91. The former Media.size is now Media.scale. It's a choice field with five options:

SIZE_CHOICES = (
    ('micro', _('<0,1 mm')),
    ('tiny', _('0,1–1,0 mm')),
    ('visible', _('1,0–10 mm')),
    ('large', _('10–100 mm')),
    ('huge', _('>100 mm'))
)

A few things are pending:

  • Removing the size category and its size tags. I think it makes sense to keep the scale as a field apart, and not a tag anymore. The main reason is that it gets complicated to get the media size, having to filter tags by category.
  • Including the scale field in the main search form.
  • Including the scale field in the dashboard metadata editing forms. ded00f3

And a question remains. Should the scale be a model with its fields? To be decided later…

@bruvellu
Copy link
Owner Author

After removing the size tags, the size descriptions in the organization page broke. Having a Scale model is indeed the best option. But since it involves additional modifications in the metadata forms, for example, this will have to be postponed for now.

@bruvellu bruvellu self-assigned this Sep 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement Issues with improvements for existing features
Projects
None yet
Development

No branches or pull requests

1 participant