Skip to content
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

refactor: markdown #1357

Merged
merged 95 commits into from
Sep 26, 2023
Merged
Show file tree
Hide file tree
Changes from 78 commits
Commits
Show all changes
95 commits
Select commit Hold shift + click to select a range
90c0a37
feat: remove old markdown logic
flornkm Sep 13, 2023
b4247ba
Merge branch 'main' into markdown-refactor
flornkm Sep 13, 2023
2fec886
feat: markdown to html
flornkm Sep 13, 2023
915be43
feat: render content into page
flornkm Sep 14, 2023
37f7c70
feat: use remark-rehype
flornkm Sep 14, 2023
b6d5de1
Merge branch 'main' into markdown-refactor
flornkm Sep 14, 2023
a99c14e
feat: render github markdown
flornkm Sep 14, 2023
cccee57
feat: basic styling
flornkm Sep 14, 2023
48892c4
feat: create own directives
flornkm Sep 14, 2023
39565f4
feat: docs getting rendered
flornkm Sep 14, 2023
6a10d9e
chore: remove frontmatter
flornkm Sep 14, 2023
e72e2b9
feat: make documentation switchable
flornkm Sep 14, 2023
0326cf0
feat: derive the title from #
flornkm Sep 14, 2023
8b3cd14
chore: minor changes
flornkm Sep 14, 2023
155becd
feat: generate title
flornkm Sep 14, 2023
f5394cb
feat: better code structure
flornkm Sep 15, 2023
b9c93c8
feat: render titles (not working atm)
flornkm Sep 15, 2023
555e544
feat: introduce inlang/markdown
flornkm Sep 15, 2023
c47edc8
feat: write test for markdown
flornkm Sep 15, 2023
64e8635
fix: typesafety
flornkm Sep 15, 2023
1173bad
feat: tags whitelist
flornkm Sep 15, 2023
5c10247
feat: render headings correctly
flornkm Sep 15, 2023
f2eb4fd
fix: headings of docs subpage
flornkm Sep 18, 2023
c83cce8
Merge branch 'main' into markdown-refactor
flornkm Sep 18, 2023
0ce3dc4
fix: package dev and build script
flornkm Sep 18, 2023
5ca6708
feat: set up tailwind for convert file
flornkm Sep 18, 2023
784590d
chore: include markdown css in docs
flornkm Sep 18, 2023
1c882e5
feat: implement lit components
flornkm Sep 18, 2023
ef45623
feat: implementation of doc-figure
flornkm Sep 18, 2023
36a6fda
feat: implement quick link lit component
flornkm Sep 18, 2023
fc58abe
fix: styling and whitelabel
flornkm Sep 19, 2023
1082090
fix: make docs work again
flornkm Sep 19, 2023
cdb506f
feat: insert metaData from tableOfContents
flornkm Sep 19, 2023
ffaeeed
feat: implement headings
flornkm Sep 19, 2023
6691c92
fix: anchor link styling
flornkm Sep 19, 2023
cf940e7
feat: edit button works again
flornkm Sep 20, 2023
0492f93
feat: enable mermaid to get shown
flornkm Sep 20, 2023
e5b8c53
feat: iconify web components
flornkm Sep 20, 2023
f18551e
feat: web icons
flornkm Sep 20, 2023
b67af5f
chore: remove web icon
flornkm Sep 20, 2023
b7e3ffe
feat: update blog tableOfContents
flornkm Sep 20, 2023
39b109b
feat: update docs
flornkm Sep 20, 2023
4627d49
feat: change dark theme
flornkm Sep 20, 2023
41845ef
chore: updating the blog
flornkm Sep 20, 2023
f9b90b5
feat: update marketplace registry to support multi structure
flornkm Sep 20, 2023
a5b15ce
fix: minor fixes
flornkm Sep 20, 2023
815037f
fix: remark-gfm
flornkm Sep 20, 2023
667cf32
chore: implement proper styling
flornkm Sep 21, 2023
0ec92a6
chore: further styling
flornkm Sep 21, 2023
f6d91e3
feat: introducing custom nodes
flornkm Sep 21, 2023
17ce5ba
feat: rewrite element nodes
flornkm Sep 21, 2023
9662cfd
feat: external link display
flornkm Sep 21, 2023
7d7ddc6
fix: a tag
flornkm Sep 21, 2023
9f48b8b
fix: preserve scroll position
flornkm Sep 21, 2023
4fa1dba
feat: implement multi-pages for marketplace
flornkm Sep 21, 2023
86c4548
feat: reset changes of tableOfContents
flornkm Sep 21, 2023
7379b29
feat: display headings
flornkm Sep 21, 2023
a02728f
feat: put content on the left side
flornkm Sep 21, 2023
eaca571
feat: new styling implementation
flornkm Sep 22, 2023
c3122b2
feat: click on anchor links
flornkm Sep 22, 2023
49db5fc
fix: docs
flornkm Sep 22, 2023
de9cfea
fix: scroll to element
flornkm Sep 22, 2023
593bc68
feat: accordingly scroll to element
flornkm Sep 22, 2023
300e7fb
Merge branch 'main' into markdown-refactor
flornkm Sep 22, 2023
57ef3be
feat: scroll behaviour
flornkm Sep 22, 2023
14fbed7
fix: mermaid language
flornkm Sep 22, 2023
0bd3c09
feat: shoelace notifications
flornkm Sep 22, 2023
899e091
chore: blog anchors
flornkm Sep 22, 2023
e31cb82
chore: small styling change
flornkm Sep 22, 2023
aec90c3
fix: install missing dependencies
flornkm Sep 22, 2023
dbb0ec8
fix: package.json
flornkm Sep 22, 2023
4cf1af3
feat: include fallback for small readmes
flornkm Sep 22, 2023
daa0802
fix: hopefully CI
flornkm Sep 22, 2023
019e87c
feat: add playwright for mermaid
flornkm Sep 22, 2023
babd3e3
feat: fix stickiness of mobile navbar and adjust timeout
flornkm Sep 22, 2023
8d0ee0f
chore: take package-lock from main branch
flornkm Sep 22, 2023
6ec93e8
chore: fix last things
flornkm Sep 22, 2023
4fafa84
feat: sections in marketplace tableOfContents
flornkm Sep 23, 2023
f85a4e4
feat: copy element as lit web component
flornkm Sep 23, 2023
4874e9c
chore: delete tableOfContents
flornkm Sep 23, 2023
e148ac2
chore: resolve issues @samuelstroschein has reviewed
flornkm Sep 23, 2023
8caf103
chore: getting rid of mermaid
flornkm Sep 25, 2023
db69211
chore: more spacing
flornkm Sep 25, 2023
603163f
feat: render blog with new order
flornkm Sep 25, 2023
fbfca6e
fix: resolve documentation code
flornkm Sep 25, 2023
a1c3d8f
feat: introduce gallery in marketplace
flornkm Sep 25, 2023
111d8de
fix: marketplace tests
flornkm Sep 25, 2023
f9a31fc
Merge branch 'main' into markdown-refactor
flornkm Sep 25, 2023
da1acb1
fix: last bugfixes
flornkm Sep 25, 2023
e7c6bd2
fix: update docs
flornkm Sep 25, 2023
60b2602
fix: update marketplace icon
flornkm Sep 25, 2023
2880b2b
chore: change missing translation image
flornkm Sep 25, 2023
77e141b
fix: small style adjustment
flornkm Sep 26, 2023
29a1e93
Merge branch 'main' into markdown-refactor
flornkm Sep 26, 2023
57b0900
fix: doc- prefix
flornkm Sep 26, 2023
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
1 change: 0 additions & 1 deletion .prettierrc.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{
"semi": false,
"useTabs": true,
"trailingComma": "all",
"printWidth": 100
}
8 changes: 1 addition & 7 deletions inlang/blog/git-as-sdk.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: What if a Git SDK to build apps exists?
href: /blog/git-as-sdk
description: Git as a backend and content database might be superior to database driven solutions for apps like Figma, Google Docs, & Co.
---

# {% $frontmatter.title %}
# What if a Git SDK to build apps exists?

While exploring how to design a developer-first localization solution (also known as i18n, aka offering software in different human languages), I realized that git as a backend might be superior to database driven solutions for applications like Figma, Google Docs, & Co. I refer to a cloud-based backend as a backend where users operate on documents that are stored in a database, opposed to documents in the form of files.

Expand Down
8 changes: 1 addition & 7 deletions inlang/blog/inlang-refactor.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Refactoring Inlang
href: /blog/refactoring-inlang
description: Inlang got a major refactor which brings new capabilities to the ecosystem.
---

# {% $frontmatter.title %}
# Refactoring Inlang

![architecture inlang new](https://cdn.jsdelivr.net/gh/inlang/monorepo/inlang/documentation/assets/architecture.jpg)

Expand Down
8 changes: 1 addition & 7 deletions inlang/blog/notes-on-git-based-architecture.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: "March 2022: Does a git-based architecture make sense?"
href: /blog/notes-on-git-based-architecture
description: Internal notes from March 2022 on why a git-based architecture for localization and beyond seems to make sense.
---

# {% $frontmatter.title %}
# March 2022: Does a git-based architecture make sense?

This document has been written by me, [@samuelstroschein](https://twitter.com/samuelstroschein), as a note to myself on why a git-based architecture makes sense.

Expand Down
28 changes: 24 additions & 4 deletions inlang/blog/tableOfContents.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,26 @@
[
"./inlang-refactor.md",
"./the-next-git.md",
"./git-as-sdk.md",
"./notes-on-git-based-architecture.md"
{
"path": "./inlang-refactor.md",
"slug": "inlang-refactor",
"title": "Refactoring Inlang",
"description": "Inlang got a major refactor which brings new capabilities to the ecosystem."
},
{
"path": "./the-next-git.md",
"slug": "the-next-git",
"title": "The next git",
"description": "Git, or more generalized version control, seems to be an appropriate backend for content heavy apps."
},
{
"path": "./git-as-sdk.md",
"slug": "git-as-sdk",
"title": "What if a Git SDK to build apps exists?",
"description": "Git as a backend and content database might be superior to database driven solutions for apps like Figma, Google Docs, & Co."
},
{
"path": "./notes-on-git-based-architecture.md",
"slug": "notes-on-git-based-architecture",
"title": "March 2022: Does a git-based architecture make sense?",
"description": "Internal notes from March 2022 on why a git-based architecture for localization and beyond seems to make sense."
}
]
17 changes: 3 additions & 14 deletions inlang/blog/the-next-git.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,9 @@
---
title: The next git
href: /blog/the-next-git
description: Git, or more generalized version control, seems to be an appropriate backend for content heavy apps.
---

# {% $frontmatter.title %}
# The next git

**Inlang might bring version control to domains outside of software engineering.**

{% Figure

src="https://cdn.jsdelivr.net/gh/inlang/monorepo/inlang/documentation/assets/what-if-1000-artists.jpeg"
alt="What if 1000s of artists are able to create a song together?"
caption="A slide from one of the first presentations about inlang being built on git, and the possibilities version control might open. The image has been taken from the iconic iPod campaign."

/%}
<display-figure src="https://cdn.jsdelivr.net/gh/inlang/monorepo/inlang/documentation/assets/what-if-1000-artists.jpeg" alt="What if 1000s of artists are able to create a song together?" caption="What if 1000s of artists are able to create a song together?"
caption="A slide from one of the first presentations about inlang being built on git, and the possibilities version control might open. The image has been taken from the iconic iPod campaign."></display-figure>

Inlang is git-based localization infrastructure and, simultaneously, a case study for version control-based applications. Git provides unprecedented (async) collaboration, automation, and simple review flows out of the box. Wouldn't version control be benefitial to domains outside of software engineering? What if artists could collaborate on a song in the way software engineers collaborate on open source software? What if open source mechanical engineering would be as common as open source software? What if... version control enables new workflows and apps with built-in version control are better than their counterparts?

Expand Down
10 changes: 2 additions & 8 deletions inlang/documentation/concept/app.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
---
title: App
href: /documentation/app
description: An inlang app provides a user interface for a project.
---
# App

# {% $frontmatter.title %}

{% $frontmatter.description %} A wide variety of apps for many different use-cases exists. Go to the [marketplace](/marketplace) to find apps that fit your needs.
An inlang app provides a user interface for a project. A wide variety of apps for many different use-cases exists. Go to the [marketplace](/marketplace) to find apps that fit your needs.

![inlang app concept](https://cdn.jsdelivr.net/gh/inlang/monorepo/inlang/documentation/assets/app.jpg)

Expand Down
8 changes: 1 addition & 7 deletions inlang/documentation/concept/language-tag.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Language tag
href: /documentation/language-tag
description: TODO TODO TODO TODO TODO
---

# {% $frontmatter.title %}
# Language tag

A language tag is a standardized code or tag that is used to identify human languages and regions.

Expand Down
10 changes: 2 additions & 8 deletions inlang/documentation/concept/library.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,3 @@
---
title: Library
href: /documentation/library
description: Developers can use inlang libraries for their own software projects.
---
# Library

# {% $frontmatter.title %}

{% $frontmatter.description %} A wide variety of libraries for different use-cases exists. Go to the [marketplace](/marketplace) to find a library that fit your needs.
Developers can use inlang libraries for their own software projects. A wide variety of libraries for different use-cases exists. Go to the [marketplace](/marketplace) to find a library that fit your needs.
10 changes: 2 additions & 8 deletions inlang/documentation/concept/lint-rule.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
---
title: Lint rule
href: /documentation/lint-rule
description: Lint rules validate messages and other types of content in an inlang project.
---
# Lint rule

# {% $frontmatter.title %}

{% $frontmatter.description %}
Lint rules validate messages and other types of content in an inlang project.

For example, the [missing translation lint rule](/marketplace/messageLintRule.inlang.missingTranslation) reports an issue if a message is missing a translation for a specified [language tag](/documentation/concepts/language-tag). Inlang applications use lint rules to validate content and report issues to the user.

Expand Down
8 changes: 1 addition & 7 deletions inlang/documentation/concept/message.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Message
href: /documentation/message
description: TODO TODO TODO TODO TODO
---

# {% $frontmatter.title %}
# Message

A message is a piece of text that is displayed to the user. Everything within an application, like the text on a button, is a message. A message itself is composed of variants. User preferences like language or region determine which variant is displayed. Inlang's message handling is based on the [ICU Message Format 2.0](https://github.com/unicode-org/message-format-wg/blob/main/spec/syntax.md).

Expand Down
10 changes: 2 additions & 8 deletions inlang/documentation/concept/plugin.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
---
title: Plugin
href: /documentation/plugin
description: An inlang plugin defines and extend how an inlang app should behave.
---
# Plugin

# {% $frontmatter.title %}

{% $frontmatter.description %}
An inlang plugin defines and extend how an inlang app should behave.

For example, plugin A defines that [messages](/documentation/message) should be stored in a database, while plugin B defines that messages should be stored in a file. An [inlang app](/documentation/app) that uses plugin A will store messages in a database, while an inlang app that uses plugin B will store messages in a file.

Expand Down
8 changes: 1 addition & 7 deletions inlang/documentation/concept/project.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Project
href: /documentation/project
description: TODO TODO TODO TODO TODO
---

# {% $frontmatter.title %}
# Project

An inlang project is defined by a file that is named `project.inlang.json`. The file contains the settings for a project and is the entrypoint for all applications, plugins, and tools in the inlang ecosystem.

Expand Down
8 changes: 1 addition & 7 deletions inlang/documentation/guide/develop-app.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Develop an app
href: /documentation/develop-app
description: How to develop an inlang-based app.
---

# {% $frontmatter.title %}
# Develop an app

There are many ways users interact with inlang. This documentation gives you information on how to develop your own inlang-based app.

Expand Down
8 changes: 1 addition & 7 deletions inlang/documentation/guide/develop-lint-rule.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Develop a lint rule
href: /documentation/develop-lint-rule
description: Create an own lint rule for inlang projects.
---

# {% $frontmatter.title %}
# Develop a lint rule

This documentation provides step-by-step instructions on developing a lint rule for the inlang ecosystem. Lint rules are used to check for specific patterns or issues in translated messages to ensure high-quality translations. Follow the guide below to create your own custom lint rule.

Expand Down
8 changes: 1 addition & 7 deletions inlang/documentation/guide/develop-plugin.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Develop a plugin
href: /documentation/develop-plugin
description: Learn how easy it is to write your own plugin for inlang projects.
---

# {% $frontmatter.title %}
# Develop a plugin

Plugins are a powerful way to extend the functionality of inlang applications. This documentation provides you with the information you need to develop your own plugin.

Expand Down
8 changes: 1 addition & 7 deletions inlang/documentation/guide/publish-marketplace.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Publish to the marketplace
href: /documentation/publish-marketplace
description: Reach more of your target audience by publishing your app, plugin, or lint rule to the marketplace.
---

# {% $frontmatter.title %}
# Publish to the marketplace

Publishing your own plugin or lint rule to the [marketplace](/marketplace) is straightforward, as the only thing you have to add to our item registry is the URL of your `marketplace-manifest.json`.

Expand Down
8 changes: 1 addition & 7 deletions inlang/documentation/overview/architecture.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Architecture
href: /documentation/architecture
description: TODO TODO TODO TODO TODO
---

# {% $frontmatter.title %}
# Architecture

Inlang's architecture consists of four main components:

Expand Down
48 changes: 8 additions & 40 deletions inlang/documentation/overview/introduction.md
Original file line number Diff line number Diff line change
@@ -1,56 +1,24 @@
---
title: Introduction
href: /documentation
description: Inlang is globalization infrastructure that powers an ecosystem of apps, plugins, and solutions that make globalization simple.
---

# {% $frontmatter.title %}
# Introduction

## What is inlang?

{% $frontmatter.description %}
Inlang is globalization infrastructure that powers an ecosystem of apps, plugins, and solutions that make globalization simple.

![inlang ecosystem](https://cdn.jsdelivr.net/gh/inlang/monorepo/inlang/documentation/assets/ecosystem.jpg)

### Infrastructure approach

For every use case, there is an app, a plugin, a lint rule, or a custom solution that can be built. Inlang's infrastructure powers an ecosystem of tools, applications, best practices, and automations for organizations to go global.

{% Figure
src="https://cdn.jsdelivr.net/gh/inlang/monorepo/inlang/documentation/assets/project.jpg"
alt="one config file to power all infrastructure tools"
caption="Sketch about the concept of one configuration file that powers all tools, automation, and applications for globalization that developers build on top of."

/%}
<doc-figure src="https://cdn.jsdelivr.net/gh/inlang/monorepo/inlang/documentation/assets/project.jpg" alt="one config file to power all infrastructure tools" caption="Sketch about the concept of one configuration file that powers all tools, automation, and applications for globalization that developers build on top of."></doc-figure>

### Version control and automation via CI/CD

Inlang apps are built on lix. Lix is a git-compatible version control backend for applications. Using lix provides inlang with CI/CD for globalization and collaboration between developers, translators, and designers on one common source of truth: your repository and your data.

{% Figure

src="https://github.com/inlang/monorepo/assets/58360188/917cc987-669d-4203-a2ed-8184087fd070"

alt="lix-based globalization infrastructure"

caption="Lix repositories act as building blocks for tools, applications like the editor, and automation via CI/CD."

/%}

{% QuickLinks %}

{% QuickLink
title="Getting started"
icon="fast"
href="/documentation/manually-create-project"
description="Create a new project."
/%}

{% QuickLink
title="Marketplace"
icon="add-plugin"
href="/marketplace"
description="Find apps, plugins, and lint rules."
/%}
<doc-figure src="https://github.com/inlang/monorepo/assets/58360188/917cc987-669d-4203-a2ed-8184087fd070" alt="lix-based globalization infrastructure" caption="Lix repositories act as building blocks for tools, applications like the editor, and automation via CI/CD."></doc-figure>

{% /QuickLinks %}
<doc-links>
<doc-link title="Getting started" icon="material-symbols:fast-forward-outline-rounded" href="/documentation/manually-create-project" description="Create a new project."></doc-link>
<doc-link title="Marketplace" icon="material-symbols:code-blocks-rounded" href="/marketplace" description="Find apps, plugins, and lint rules."></doc-link>
</doc-links>
8 changes: 1 addition & 7 deletions inlang/documentation/overview/manually-create-project.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Manually creating a new project
href: /documentation/manually-create-project
description: You can manually create a new project if inlang.com/new is not working for you.
---

# {% $frontmatter.title %}
# Manually creating a new project

You can manually create a new project via the CLI or by creating an inlang project file.

Expand Down
8 changes: 1 addition & 7 deletions inlang/documentation/reference/comver.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
---
title: Backwards compatible versioning
href: /documentation/comver
description: You can manually create a new project if inlang.com/new is not working for you.
---

# {% $frontmatter.title %}
# Backwards compatible versioning

> Is this update backwards compatible?

Expand Down
8 changes: 1 addition & 7 deletions inlang/documentation/reference/sdk.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,3 @@
---
title: SDK
href: /documentation/sdk
description: API reference for the inlang SDK. Developers can use the inlang SDK to build inlang applications.
---

# {% $frontmatter.title %}
# SDK

The documentation for the inlang SDK is currently under construction and coming soon. In the meantime, please refer to the [inlang SDK on GitHub](https://github.com/inlang/monorepo/blob/main/inlang/source-code/sdk/src/index.ts) or [join our Discord](https://discord.gg/gdMPPWy57R) to get help from our team.
37 changes: 37 additions & 0 deletions inlang/documentation/reference/tableOfContents.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Table of Contents

inlang's website is using a custom structure for the table of contents. A real example of the structure can be found here: [tableOfContents.json](https://github.com/inlang/monorepo/blob/main/inlang/documentation/tableOfContents.json)

## Structure

### Variant 1

This variant can be used for a flat table of contents.

```json
[
{
"path": "path-to-file.md",
"slug": "slug-of-url", // has to be unique
"title": "Title of the page",
"description": "Description of the page",
}
]
```

flornkm marked this conversation as resolved.
Show resolved Hide resolved
### Variant 2

This variant can be used for a table of contents with categories.

```json
{
"Category Name": [
{
"path": "path-to-file.md",
"slug": "slug-of-url", // has to be unique
"title": "Title of the page",
"description": "Description of the page",
}
]
}
```
Loading