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
modern-ysu-thesis:0.1.0 #634
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for submitting this package. There are two issues that have to be solved before it can get merged. The first one is that Typst package can't currently ship fonts, and including them in a folder as you didn't won't work. Could you please delete this folder, and add a link in the README where users can download the required fonts if they don't have them?
The second issue is with the example figure in the template, as explained below.
])) | ||
|
||
#figure( | ||
image("..\assets\vi\ysulogo.png", width: 20%), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This won't work, as this file will not be copied when creating a project from this template. If you consider that this logo is important enough to be used by most people who use your package, you can export it from the package itself by adding this in lib.typ
(or some other file, and re-exporting it here):
#let logo = image.with("assets/vi/ysulogo.png")
And then, in your template, you can do:
#logo(width: 20%)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok,i am sorry that i am busy in do my thesis and no see this reply ,i will fix these as quick as i can
92aab43
to
d06d87c
Compare
image("..\assets\vi\ysulogo.png", width: 20%), | ||
caption: [图片测试], | ||
) <ysu-logo> | ||
#let logo = image.with("assets/vi/ysulogo.png") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to be defined in the package (e.g. lib.typ
) and imported from there.
This is because here, it will be resolved relative to the user's working directory / the project root whereas in the package, resolution is relative to the package root. Since the file is in the package, only the latter will work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok,i have remove the picture
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removing the logo works. I have attached a review that shows how to do it - let me know if you want to apply the change!
#import "utils/style.typ": 字号 | ||
|
||
#import "layouts/page-header.typ": page-header | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removing the logo works too, but you could also add it here and have the package work as you intended:
#let logo = image.with("assets/vi/ysulogo.png") | |
@@ -0,0 +1,220 @@ | |||
#import "@preview/modern-ysu-thesis:0.1.0": documentclass, indent |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#import "@preview/modern-ysu-thesis:0.1.0": documentclass, indent | |
#import "@preview/modern-ysu-thesis:0.1.0": documentclass, indent, logo |
) <timing-tlt> | ||
])) | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#logo(width: 20%) |
well,the logo just a example to tell user how to add picture and is not necessary,i don't want user confuse by lib.typ,so just remove it ,maybe user can learn how to add picture to there thesis by google. |
Okay, let's merge this then. Thank you! |
I am submitting
Description: Explain what the package does and why it's useful.
I have read and followed the submission guidelines and, in particular, I
typst.toml
file with all required keysREADME.md
with documentation for my packageLICENSE
file or linked one in myREADME.md
exclude
d PDFs or README images, if any, but not the LICENSE