Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,8 @@ precommit: lint test
cli:
poetry run tkdesigner ${FIGMA_PROJECT_URL} ${FIGMA_TOKEN} -f

cli.build.test:
poetry run tkdesigner https://www.figma.com/file/WVLnulVsI177tvnxSdqOUZ/Untitled ${FIGMA_TOKEN} -f

Comment on lines +31 to +33
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest that you remove this link for that external dependency because this maybe to cause failures in the next builds if this resource does unavailable.

gui:
poetry run python gui/gui.py
2 changes: 2 additions & 0 deletions tkdesigner/figma/custom_elements.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ def __init__(self, node, frame, image_path, *, id_):
super().__init__(node, frame)
self.image_path = image_path
self.id_ = id_
self.frame = frame

def to_code(self):
return f"""
Expand All @@ -20,6 +21,7 @@ def to_code(self):
image=button_image_{self.id_},
borderwidth=0,
highlightthickness=0,
activebackground="{self.frame.color()}",
command=lambda: print("button_{self.id_} clicked"),
relief="flat"
)
Expand Down