diff options
Diffstat (limited to 'ui/article_detail.py')
| -rw-r--r-- | ui/article_detail.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ui/article_detail.py b/ui/article_detail.py index 1fe1643..a0464ae 100644 --- a/ui/article_detail.py +++ b/ui/article_detail.py @@ -38,9 +38,13 @@ class ArticleDetailView(QWidget): self._title_label.setStyleSheet("color: #fff; font-weight: bold; font-size: 13px;") self._path_label = QLabel("") self._path_label.setStyleSheet("color: #555; font-size: 10px;") + self._draft_badge = QLabel("● DRAFT") + self._draft_badge.setStyleSheet("color:#f59e0b; font-size:10px; font-weight:bold;") + self._draft_badge.hide() info = QVBoxLayout() info.addWidget(self._title_label) info.addWidget(self._path_label) + info.addWidget(self._draft_badge) h_layout.addLayout(info, stretch=1) for (icon, signal_name, style) in [ @@ -106,6 +110,7 @@ class ArticleDetailView(QWidget): self._title_label.setText(article.slug) rel = "/".join(article.path.parts[-5:]) self._path_label.setText(rel) + self._draft_badge.setVisible(article.draft) # Populate frontmatter while self._fm_content.count(): |
