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

Simplify Image url handling #24

Closed
2 tasks done
StaehliJ opened this issue Oct 20, 2023 · 1 comment · Fixed by #25
Closed
2 tasks done

Simplify Image url handling #24

StaehliJ opened this issue Oct 20, 2023 · 1 comment · Fixed by #25
Labels
enhancement New feature or request

Comments

@StaehliJ
Copy link
Contributor

Use case description

After an update, it seem that IlImage does nothing special anymore like ImageUrl that only generate an IlImage.

Acceptance criteria

ImageProvider is still easily usable

Proposed solution

Remove both classes and replace with a string each ImageUrl.

Alternatives considered

Do nothing

Is there an existing similar feature request?

  • I have searched existing features and found no similar request.

  • I have browsed the available API and found no way to achieve the use case I described.

@StaehliJ StaehliJ added the enhancement New feature or request label Oct 20, 2023
@StaehliJ
Copy link
Contributor Author

StaehliJ commented Oct 20, 2023

Proposition:

val media: Media
media.imageUrl.url(ImageWidth.W1920)
media.imageUrl.url(ImageWidth.W1920, IlHost.TEST)

val chapter: Chapter
chapter.imageUrl.url(ImageSize.MEDIUM)
  
val defaultDecorator = DefaultImageUrlDecorator(IlHost.PROD) // or custom decorator
media.imageUrl.url(defaultDecorator, ImageSize.MEDIUM)

@StaehliJ StaehliJ linked a pull request Oct 20, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant