Skip to content

Commit

Permalink
table experiments
Browse files Browse the repository at this point in the history
  • Loading branch information
jkulawik committed Apr 25, 2024
1 parent 866aaa9 commit 51ad61d
Show file tree
Hide file tree
Showing 4 changed files with 59 additions and 0 deletions.
3 changes: 3 additions & 0 deletions TODO.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
* move header and tag stuff to _data? See: https://jekyllrb.com/docs/datafiles/
* table template: https://jekyllrb.com/tutorials/csv-to-table/
* syntax highlighting css https://github.com/jwarby/jekyll-pygments-themes

Done
* change favicon
Expand Down
3 changes: 3 additions & 0 deletions _data/chat-apps.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
App,Group VC,Multichannel,Custom emoji,Networking,Pricing,FOSS,Normie design
Telegram,yes,yes,yes,centralized,free,no,yes
Mattermost,paid feature,yes,yes,unfederated,freemium,no,no
38 changes: 38 additions & 0 deletions _drafts/table.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
---
layout: post
title: "Table"
tags: []
---
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

{% highlight python %}
def bubble_sort(items):
""" Implementation of bubble sort """
for i in range(len(items)):
for j in range(len(items)-1-i):
if items[j] > items[j+1]:
# Swap!
items[j], items[j+1] = items[j+1], items[j]
{% endhighlight %}

```
code test
```

`inline code`


|App |Group VC |Multichannel|Custom emoji|Networking |Pricing |FOSS|Normie design|
|----------------|------------|------------|------------|-------------|--------|----|-------------|
|Telegram |yes |yes |yes |centralized |free |no |yes |
|Mattermost |paid feature|yes |yes |decentralized|freemium|no |no |


{% include csv-table.html data=site.data.chat-apps %}


*[VC]: Voice chat / video chat
*[Multichannel]: Whether chatrooms are grouped and managed together, or the app is based on separate group chats, like in a phone app or in IRC.
*[Normie design]: Many apps have the annoying interface style with huge profile pictures and chatroom icons, and speech bubbles in chats.
*[Networking]: Whether the app is centralized, decentralized, or decentralized and federated.
*[FOSS]: Free and open-source
15 changes: 15 additions & 0 deletions _includes/csv-table.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<table>
{% for row in include.data %}
{% if forloop.first %}
<tr>
{% for pair in row %}
<th>{{ pair[0] }}</th>
{% endfor %}
</tr>
{% endif %}

{% tablerow pair in row %}
{{ pair[1] }}
{% endtablerow %}
{% endfor %}
</table>

0 comments on commit 51ad61d

Please sign in to comment.