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

Remove unpublished fork ricardoboss/easysvg #87

Closed
JellyBellyDev opened this issue Feb 18, 2022 · 6 comments · Fixed by #89
Closed

Remove unpublished fork ricardoboss/easysvg #87

JellyBellyDev opened this issue Feb 18, 2022 · 6 comments · Fixed by #89
Assignees
Labels

Comments

@JellyBellyDev
Copy link
Collaborator

Bug Report

Q A
BC Break no
Library Version 2.3.0
PHP version 7.4

Summary

Remove unpublished fork ricardoboss/easysvg deps to composer.json as soon as the PR is released: kartsims/easysvg#32

Assigned to @ricardoboss :)
Ok?

@ricardoboss
Copy link
Collaborator

Sure! @JellyBellyDev

@antonkomarev
Copy link
Collaborator

antonkomarev commented Feb 20, 2022

Cannot install v2.3

$ composer require badges/poser:^2.3

./composer.json has been updated
Running composer update badges/poser
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Root composer.json requires badges/poser ^2.3 -> satisfiable by badges/poser[v2.3.0, 2.x-dev].
    - badges/poser[v2.3.0, ..., 2.x-dev] require kartsims/easysvg ^2.0 -> found kartsims/easysvg[dev-master, 1.0] but it does not match the constraint.

Previous badges were implemented without extra dependency 😢

@ricardoboss
Copy link
Collaborator

You need to add my fork as a repository so composer can find version 2.3:

    "repositories": [
        {
            "type": "vcs",
            "url": "https://github.com/ricardoboss/easysvg"
        }
    ]

Once my fork (kartsims/easysvg#32) is merged, this will no longer be necessary

@antonkomarev
Copy link
Collaborator

@ricardoboss thank you for the example. How this dependency is better than solution with font size detection implemented in other badges?

@ricardoboss
Copy link
Collaborator

In my original PR, I used this library to not only calculate the font size, but also to generate SVG paths for the letters in the badge. Later, after revisiting which fonts are used, I merely used the library for it's features with letter spacing and kerning.

If I remember correctly, the current implementation for text width calculation doesn't support this. Also, the for-the-badge style needs different styling in that the value needs to be bold.

@ricardoboss
Copy link
Collaborator

@JellyBellyDev @antonkomarev A new version of kartsims/easysvg was published (2.4). I will open a PR to close this issue.

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

Successfully merging a pull request may close this issue.

3 participants