Skip to content

Commit d57455f

Browse files
style: power k page improvements. (#52)
* fix indentation. * add callouts.
1 parent c43be83 commit d57455f

File tree

3 files changed

+56
-5
lines changed

3 files changed

+56
-5
lines changed

markdoc/tags.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import { ExpansionTile } from '@/components/ExpansionTile'
88
import { UrlEmbed } from '@/components/UrlEmbed'
99
import React from 'react'
1010
import { InlineCode } from '@/components/Inline-code'
11+
import IconCallout from '@/components/IconCallout'
1112

1213
const tags = {
1314
callout: {
@@ -22,6 +23,15 @@ const tags = {
2223
},
2324
render: Callout,
2425
},
26+
'icon-callout': {
27+
attributes: {
28+
title: { type: String },
29+
icon: { type: String },
30+
image: { type: Boolean, default: false },
31+
className: { type: String, default: '' },
32+
},
33+
render: IconCallout,
34+
},
2535
figure: {
2636
selfClosing: true,
2737
attributes: {

src/components/IconCallout.jsx

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
import React from 'react'
2+
import Image from 'next/image'
3+
4+
const IconCallout = ({ title, children, icon, image = false, className }) => {
5+
return (
6+
<div className="h-full py-4">
7+
<div
8+
className={`flex h-full gap-4 rounded-lg border-2 p-4 ${className}`}
9+
>
10+
<div>
11+
{image ? (
12+
<div className="h-6 w-6 flex-shrink-0">
13+
<Image src={icon} alt="icon" className="mt-1.5 h-6 w-6" />
14+
</div>
15+
) : (
16+
<div className="relative -mt-1 mb-auto flex h-4 flex-shrink-0 text-2xl">
17+
{icon}
18+
</div>
19+
)}
20+
</div>
21+
<div>
22+
{title && <div className="text-lg font-semibold">{title}</div>}
23+
{children && (
24+
<div className={`-mb-2 text-gray-500 ${!title && '-mt-2'} `}>
25+
{children}
26+
</div>
27+
)}
28+
</div>
29+
</div>
30+
</div>
31+
)
32+
}
33+
34+
export default IconCallout

src/pages/power-k.md

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,28 +18,35 @@ Power K, formerly called the Command Menu or just CMD + K, is a list of shortcut
1818
- Expand the scope of this search to include projects in your workspace with just a toggle—powerful when you have several projects and are hunting an issue in all of them.
1919
![Untitled](/images/power-k/search-2.png)
2020

21-
🎯 **Roadmap item**
21+
{% icon-callout title="Roadmap item" icon="🎯" %}
2222
Search profiles, comments, and issue descriptions
23+
{% /icon-callout %}
2324

2425
### Quick access
2526

2627
- Workspace and preference settings
28+
2729
Quickly toggle between light and dark mode or access workspace settings for APIs and Webhooks in just two clicks.
2830
![Untitled](/images/power-k/quick-access-1.png)
31+
2932
- Keyboard shortcuts
33+
3034
Get to your list of keyboard shortcuts with the Power K menu in two steps.
3135
![Untitled](/images/power-k/quick-access-2.png)
36+
3237
- Documentation and Support
38+
3339
Chat with us, see our docs, or report a bug—all from the Power K menu.
3440

3541
### Create
3642

3743
- Create anything—projects, issues, cycles, modules, views, pages, and even workspaces, using Power K's create options.
38-
39-
![create_project.mp4](/images/power-k/create-project.gif)
44+
![create_project.mp4](/images/power-k/create-project.gif)
4045

4146
- Press ⌘ + K on an issue page to changing states, priority, assignments or just to copy issue links.
47+
![Untitled](/images/power-k/create.png)
4248

43-
![Untitled](/images/power-k/create.png)
49+
{% icon-callout icon="🎯" %}
50+
What else should Power K, empower? [Let us know.](https://github.com/makeplane/plane)
51+
{% /icon-callout %}
4452

45-
🎯 What else should Power K, empower? [Let us know.](https://github.com/makeplane/plane)

0 commit comments

Comments
 (0)