Skip to content

Commit

Permalink
[dev] update bitgen renderer script to fix image to 100% width
Browse files Browse the repository at this point in the history
  • Loading branch information
electrovir committed Feb 13, 2024
1 parent 6ddf613 commit 6ef8805
Show file tree
Hide file tree
Showing 7 changed files with 71 additions and 18 deletions.
64 changes: 58 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@toniq-labs/toniq-nft-frame-mono-repo-root",
"version": "3.0.1",
"version": "3.0.2",
"private": true,
"license": "MIT",
"author": {
Expand Down
2 changes: 1 addition & 1 deletion packages/demo/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@toniq-labs/toniq-nft-frame-demo",
"version": "3.0.1",
"version": "3.0.2",
"private": true,
"license": "MIT",
"author": {
Expand Down
2 changes: 1 addition & 1 deletion packages/scripts/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@toniq-labs/toniq-nft-frame-scripts",
"version": "3.0.1",
"version": "3.0.2",
"private": true,
"scripts": {
"compile": "virmator compile && npm run execute",
Expand Down
2 changes: 1 addition & 1 deletion packages/tests/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@toniq-labs/toniq-nft-frame-tests",
"version": "3.0.1",
"version": "3.0.2",
"private": true,
"license": "MIT",
"author": {
Expand Down
2 changes: 1 addition & 1 deletion packages/toniq-nft-frame/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@toniq-labs/toniq-nft-frame",
"version": "3.0.1",
"version": "3.0.2",
"homepage": "https://github.com/Toniq-Labs/nft-frame",
"bugs": {
"url": "https://github.com/Toniq-Labs/nft-frame/issues"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ async function render(size, ...inscriptionIds) {
* transparency edge render artifacts, like grey borders. As long as this image gets 1 pixel
* rendered on screen for 1 frame, the artifacts will go away.
*/
const resizeArtifactFix = `
<img
class="full-size"
onload="this.remove()"
src="${generateCombinedImageUrl(size, base64Images, true)}"
/>
`;
const resizeArtifactFix = /* HTML */ `
<img
class="full-size"
onload="this.remove()"
src="${generateCombinedImageUrl(size, base64Images, true)}"
/>
`;

return /* HTML */ `
<style>
Expand All @@ -51,6 +51,7 @@ async function render(size, ...inscriptionIds) {
}
img {
display: block;
width: 100%;
}
</style>
${resizeArtifactFix}
Expand Down

0 comments on commit 6ef8805

Please sign in to comment.