typlog / issues Goto Github PK
View Code? Open in Web Editor NEWReport Issues of Typlog
Report Issues of Typlog
The following aren't documented here:
_snippets/page_qr.j2
(used by theme Ginza)_snippets/theme_toggle.j2
(used by theme Nezu & theme Ueno)block foot_html
(used by theme Nezu)block lang
(used by theme Akasaka)features.foot_html
(used by theme Nezu)features.head_html
(used by theme Akasaka & theme Meguro)(I can figure out from context what they do, so this isn't a problem; I'm just letting you know.)
I can roughly figure out what's happening from Nezu's README.md
, but maybe the mechanism is worth documenting somewhere?
On a related note: I had somehow missed the whole "Assets" thing. I'm not quite sure what they're really for, but... Interesting! And an Asset can be a Jinja template...? Intriguing!
The theme docs say:
Typlog hosts all themes on GitHub. To list your theme in Typlog theme registry, you need to create a pull request to add your theme into registry.json file.
That doesn't seem ideal?
I was thinking of taking two of the existing themes, and tweaking them. But I'm tweaking them for my particular needs; that isn't quite the same thing as creating themes for others to use.
In addition, I can think of possible problems. Here are two examples.
First, I may have some content in a site footer that's specific to my site. Typlog doesn't have a parameterization mechanism at the site level that would allow me to enter the info in the admin (the way, say, tags allow you to add arbitrary meta values), so I'd probably hard-code that content directly into the footer itself. (I can give specific examples of what I might put there.) Using HTML injection might be an alternative, but it would be an alternative that introduced its own problems. For example, that would only work for content at the very, very bottom of the page.
Second, on one of the themes I might use a font that I've purchased. If I do, I was going to put the font files on a CDN so that I could access them by URL from the template. The problem is that the font is licensed to me; I don't have the right to let others use it. Again, HTML injection might be an alternative, but it would be a slightly awkward one; the CSS, for example, would reference a font family that other users wouldn't have.
Those are two examples, but I can think of others.
It seems like there should be some mechanism that lets you use a custom theme without adding it to the list? For example: what if you could optionally enter a Github repository name directly?
Typlog 在 Moments 页面,点击图片有缩放比例不正确的 Bug
环境是macOS 的 Safari 15,在微信内、小米手机自带浏览器也能复现。
The typlog.js
typos reminded me of admin typos I had seen; this is from a quick scan of the pages:
"Make sure it's at least 15 characters OR at least 8 characters including a number and an uppercase letter."
-> "Make sure it's at least 15 characters long OR at least 8 characters long and includes at least one digit and one uppercase letter."
"Developers can use API token to access Typlog 3.0 APIs."
-> "Developers can use an API token to access the Typlog 3.0 API."
"Access to read your sites data."
-> "Ability to read your sites' data."
"If you encounter any problem, please contact us via:"
-> "If you encounter any problems, please contact us via:"
"Featured post..."
-> "Featured posts..."
"Filling in the URL of a page..."
-> "Fill in the URL of a page..."
"This will be displayed as title..."
-> "This will be displayed as the title..."
"...and will be displayed as description..."
-> "...and will be displayed as the description..."
"This will be displayed as title..."
-> "This will be displayed as the title..."
"...and will be displayed as description..."
-> "...and will be displayed as the description..."
"Allow others to subscribe to your site"
-> "Enable subscriptions"
"You need to enable Episodes feature in general settings at first."
-> "You need to enable the Episodes feature in general settings first."
"Click the below button..."
-> "Click the button below..."
"Update your site's primary and secondary theme color."
-> "Update your site's primary and secondary theme colors."
"Squared, best be 1400x1400."
-> "Square, 1400x1400 is best."
"Insert below HTML code into your site's <head> tag."
-> "Insert the following HTML into the <head> tag."
"Insert below HTML code into the top of <body> tag."
-> "Insert the following HTML at the top of the <body> tag."
"Insert below HTML code into the bottom of <body> tag."
-> "Insert the following HTML at the bottom of the <body> tag."
"Head HTML"
-> "Header HTML"
(or maybe something like "Body HTML (Top)"
)"Foot HTML"
-> "Footer HTML"
(or maybe something like "Body HTML (Bottom)"
)"...godday, and etc."
-> "godaddy, etc."
"Serve your site from your own domain other than..."
-> "Serve your site from your own domain rather than..."
"You can add credit card and account balance in the Billing page."
-> "You can add a credit card and view your balance on the Billing page."
"Add your own Google Analytics..."
-> "Add Google Analytics..."
"Send instant post to your telegram channel."
-> "Send posts to your Telegram channel."
"Add disqus comment to your website."
-> "Add Disqus comments to your website."
"Use your own chartable..."
-> "Use Chartable..."
"Share your content into your Twitter account."
-> "Share your content using your Twitter account."
or "Share your content using Twitter."
"Redirects works when a URL is 404. For instance, one is visiting https://example.com/about, but you have updated about page to https://example.com/about-us, then you can add a redirect:"
-> "Add redirects to prevent a "page not found" (404) error. If, for example, you changed the URL of the About page from https://example.com/about to https://example.com/about-us, you could add a redirect so that anyone visiting the old URL would automatically be redirected to the new one:"
"...and other content data into a JSON file."
-> "...and other content to a JSON file."
"Clean up posts, ..."
-> "Remove posts, ..."
"...from this site and destroy this site."
-> "...from this site and destroy the site."
It would be great if there was a way to subscribe to the Changelog.
(Personally, I'd prefer email to RSS; I subscribe to a lot of RSS feeds, and the changes would get lost in a lot of noise. I'm much more likely to see email.)
Ueno and Nezu both use the secondary color defined in the admin to (among other things) color the links when you hover over them in dark mode.
I had to trace through the CSS to figure that out. :-)
Since Ueno is the default theme, maybe new sites should use white as the default secondary color? Right now the default secondary color is black, which means that links turn black when you hover over them in dark mode.
Nezu hides logos on small screens. I made a change to show it on small screens in my modified version, and tagged it 0.2.0; you can see all of that here.
The logo is showing up with serve-theme
:
but not on the site:
despite the fact that it's selected in the admin:
(I even tried switching to a different theme and then back to my theme @ 0.2.0.)
For example, search for "sitemap" on Google's Create a robots.txt file page.
It occurs on lepture.com viewed on iPhone SE.
The social media icons are displayed in newline instead of floating right on top.
This could be an error, but the Ueno theme shows cover images on the Home and Archive pages, but not on the Page and Post pages.
I wanted to see if it would be possible to reverse that — to show a cover image on the Page and Post pages, but not on the Home and Archive pages.
I discovered that those decisions — about whether or not to show cover images — don't seem to actually be made in the template itself? They're made in macros like render_item()
and render_subject_content()
that aren't included with the templates.
The Admin seems to sort Episodes, Pages, Posts, etc. by ID. It would probably help to sort them the same way that query.latest_subjects()
does; that way what you see in the Admin is what you would see on the site. Likewise, it would be easier to understand what query.previous_subjects()
, etc. would produce.
On a related note, it would be good to think about how ties would be broken. I haven't experimented to figure out what the current sort key is, but a potential key is:
published_at
season
# only Episodes of courseepisode
# only Episodes of coursetitle
id
That would mean, for example, that Pages with the same published_at
date would still sort in a useful and predictable way.
One relevant question: what about drafts that haven't been published yet and don't have a published_at
date yet? The most useful thing would be to make a None
date greater than all non-None
dates. That would place them at the top of the Admin list.
P.S. I think it would also help to sort Assets, Sites, Tags, etc. by title rather than ID. But there are fewer of those things, so it matters less.
I think that's confusing to all users; it was confusing to me because I've never seen a site do that. (As I noted in another issue it was particularly confusing with the default theme, because the archive page isn't titled.)
One suggestion, of course, would be to not do that. Another would be to change the link from More to Archive on the last page; that would at least explain what's happening.
在后台链接中,填写在twitter栏的用户名,在前台会变成Unsplash的用户名。
具体状况在录屏里有。
https://user-images.githubusercontent.com/25877104/137635287-5964723a-4b7a-4648-93c6-0490f424b5a8.mp4
Posts have a "Featured" flag:
I couldn't spot anything in the docs related to it, and the themes I tried didn't seem to do anything special with a Featured post.
Is "Featured" the same as "Protected Posts" in the pricing table?
I also see a .protected
CSS class in Nezu, but it doesn't seem to be used by any of Nezu's templates? (It could be used by one of the render
macros Nezu calls though.)
Here's what I did:
Then I went to the site... and the link wasn't there.
I went back to the Settings page, refreshed it, and my first primary link disappeared.
Hmmm.
I repeated the entire sequence... and the link still wasn't there.
I then did this:
Then I went back to the site, forced a page refresh, and the link showed up.
It's not obvious that you always need an empty row?
I have serve-theme
running twice, in two separate windows, on two separate ports. They're running against the same site, and they're using the same token.
One serve-theme
is using my modified Nezu theme. The other serve-theme
is using a new theme I'm developing.
The session running the modified Nezu theme loads typlog.css
and typlog.js
successfully. The session running the new theme does not.
The problem with the session that isn't working is the URLs.
Here's the HTML from the session that's running successfully:
<link rel="stylesheet" href="https://s.typlog.com/ui/20221120-81da3ab8/typlog.css">
...
<script src="https://s.typlog.com/ui/20221120-81da3ab8/typlog.js"></script>
Here's the HTML from the session that isn't:
<link rel="stylesheet" href="typlog.css">
...
<script src="typlog.js"></script>
I don't generate the HTML in either case, so I'm not sure why they're different.
I've tried things like stopping and re-starting the sessions, but so far nothing has made a difference. One session always works; the other one never does.
The only difference, I think, is that the modified Nezu theme is on Github, while the new theme isn't (yet). I don't think that would affect serve-theme
though? Other than that, I think everything is the same?
Any thoughts?
(Btw, I'm not blocked, I'm manually loading the CSS and JS files in the meantime.)
This way of creating an admonition:
.. attention::
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
produces this HTML:
<section class="admonition attention">
<p class="admonition-title">Attention</p>
<p>...</p>
</section>
This way of creating an admonition:
```{attention}
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
```
produces this HTML:
<section class="admonition attention">
<p class="admonition-title">Attention</p>
<div class="block-code" lang="en">
<pre>
<code lang="en">... </code>
</pre>
</div>
</section>
The workaround is easy and obvious, so not really a problem, but clearly not the intended result.
When I was looking into the Twitter issues I looked at the typlog.js
source and noticed some typos:
"You have subscribed the mailling list successfully."
-> "You have subscribed to the mailing list successfully."
(or, better: "You have successfully subscribed to the mailing list."
)
"Your message has been deliveried."
-> "Your message has been delivered."
Optional: Make the palceholders for name
and email
more consistent; "Your name" and "Your email" or "Name" and "Email". (Right now they're "Your name" and "Email address"; the first is adjective + noun while the second is a compound noun.)
There are a number of issues I ran into while trialing Typlog. This is one of them, but there are others. I was able to figure out what was going on in almost all cases, but new site setup should probably get a little more attention since it affects users' critical first impressions?
In this case, the issue was that there was a More link at the bottom of the home page when there were no published posts. Clicking it took me to a mostly empty page. Very confusing!
(I eventually figured out that the last page of posts leads to the Archive page. I'll add a separate issue for that, but the default theme adds to the confusion because the Archive page doesn't have a title. That's why the page was mostly empty.)
The default theme doesn't support tags. Other themes, like Meguro, do, but... Again, from a "first impression" perspective, it's a bit odd. When I started adding tags they didn't show up, and I assumed that I was doing something wrong. I spent a bit of time looking before I realized that it might be a theme issue instead.
I don't know if there are other features that the default theme doesn't support, but: if it doesn't it probably should. (If that's not possible, maybe at least make it clear which themes support which features?)
重现步骤:
Typlog uses fairly aggressive 1 hour browser-side caching on Pages and Posts. That's not necessarily bad, but you should probably warn new users; when I first started changing settings and publishing Pages and Posts they didn't show up, even when I refreshed the browser. I eventually realized that I needed to force-refresh.
(A different and better option would be to use Etags, but maybe there's no way to do that cheaply?)
In Pages, for example, it's called URL:
In Moments it's called Location:
If there's a reason for the change in terminology, it isn't clear why.
Some closely related issues:
And some other issues I'll bundle in here:
Typlog seems to store cookies in the browser when anonymous users browse sites. That very likely means that Typlog's users (i.e., Typlog's customers) are in violation of the GDPR.
I found a reasonable explanation of the issue here; here's a relevant sampling:
The GDPR requires a website to only collect personal data from users after they have given their explicit consent to the specific purposes of its use.
Websites must comply with the following GDPR cookie requirements:
- Prior and explicit consent must be obtained before any activation of cookies (apart from whitelisted, necessary cookies).
...
California has vaguely similar rules that are described here.
It's possible that the cookies are just an oversight, and Typlog doesn't actually need them at all. If that's true, they should be removed; there's nothing more to talk about! I suspect, however, that the cookies are needed for the built-in analytics.
If that's the case, I think there are two broad options.
The first is that Typlog is able to make its analytics cookie-free; in that case, no consent is needed. (I guess? I don't know if there are other subtleties.)
The second is that Typlog isn't able to make its analytics cookie-free; in that case, Typlog would need to introduce a cookie consent mechanism.
Personally, I really, really, really hate cookie consent dialogs. I wouldn't want to use them on my site, so I'd strongly prefer a third option: the ability to turn off features that require them. (I'm specifically focusing on anonymous users here.)
Btw, for my own sites I generally use GDPR-aware analytics like Plausible.io that don't use cookies and don't require consent.
This isn't an issue for me — I plan to change or create a theme anyway — but I think it's one more thing that affects "first impressions."
Typlog suggests a square logo, and then positions the logo beside the site name. There are people like me who have existing logos, and they aren't square. Not just that — I'd say that most logos include the site (i.e., brand) name; only very large and well-known brands can get away with logos that are only symbols. (And even those brands always start with names; they only drop the names once they become well-known.)
Btw, if you agree with that, note the implication: in Western languages logos are almost always rectangular, not square, because they include words.
When I added my logo to the site, it ended up looking like this in Nezu:
That is... not good. :-) Even Ueno looks awkward:
At that point, unless I'm willing and able to modify the theme, I have only one choice: drop the use of the logo. (I can't drop the site name because it's required and used in places the logo isn't.)
I still have a Ghost trial site, and I checked to see what they do. It seems that in all of their themes they use the site name if there's no logo:
and replace the site name with the logo if you supply it:
(Those are screenshots from one theme, Journal, but I tried more than one, and they all did that.)
I also took a quick look at the theme previews on Weebly, and it looks like they do the same thing. Name or logo, never both.
Although Typlog makes beautiful use of square logos, I think Ghost's approach is more likely to yield the correct result for most people most of the time.
P.S. "...most logos include the site name..." If a site — i.e., a brand — has an identity, that identity will include a specific typeface. That's why the logo would include the site/brand name.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.