Closed patricklafrance closed 9 months ago
Interesting idea. Thanks for sharing.
I'm going to look into this.
This functionality would also be good for just linking to the main site of a domain, such as a link from docs.example.com
to example.com
.
What do you think the project config in the retype.yml
should be called? We have the url
config which represents the URL of the current project.
Config name options could be rootURL
or root
. Neither seem ideal and could be easily confused with other functionality.
Naming is indeed not obvious for this one.
I would probably try to decouple this functionality from the use case I am presenting here.
An easy one could be to add a link
property to the branding
section:
branding:
link:
text
url (or link for consistency with links)
icon
But it still can be confusing.
Maybe the branding section could be optionally templated?
Upsides:
Downsides:
Initial UI mockup...
https://github.com/retypeapp/retype/assets/62210/7dcccff5-a169-49f1-947f-6ca1830fe414
The current thought is to name this feature the hub
config:
hub:
link: retype.com
alt: Go to retype.com
Other options could be be:
hub:
link: example.com # default is empty
alt: Home # default is "Home", locale specific
icon: /static/hub.svg # custom image
target: blank # default is empty
And we might be able to build in the option for a simplified version of the config:
hub: retype.com
If link
or hub: <url-here>
is not set, then the "hub link" would not added.
The scenario above assumes I'm on a fictional docs.retype.com
and I could use the Hub link to jump to the main retype.com
website, or to another documentation hub. The URL of the hub link could be set to any external or internal URL.
Other possible names for this feature and config name could be:
home
root
jump
base
anchor
hub
Let me know what you think.
Love it, thank you 🙏🏻 "Hub" is great.
The new hub
feature has been release in Retype v3.4.0.
This config is Retype Pro only.
To enable the hub link, add a URL to the link
config. The following sample demonstrates:
hub:
link: https://example.com/ # default is empty
Special thanks to @patricklafrance for sponsoring this feature development.
Hello!
We are looking at building a hierarchy of websites for all our library projects, similar to what Adobe is doing with React Spectrum:
The mecanism to link the sites is quite basic, they add a link to return to the root site before the branding icon of every nested site:
I would like to have an option with Retype to add such a link before the header icon. I would gladly buy an Enterprise license for that feature.
Thank you,
Patrick