File tree Expand file tree Collapse file tree 5 files changed +42
-24
lines changed
navigation/navbar/marketing Expand file tree Collapse file tree 5 files changed +42
-24
lines changed Original file line number Diff line number Diff line change 1
1
use pgml_components:: component;
2
2
use sailfish:: TemplateOnce ;
3
+ use std:: fmt;
4
+
5
+ #[ derive( PartialEq , Eq , Default , Clone ) ]
6
+ pub enum Color {
7
+ #[ default]
8
+ Green ,
9
+ Blue ,
10
+ Orange ,
11
+ Pink ,
12
+ Purple ,
13
+ }
14
+
15
+ impl fmt:: Display for Color {
16
+ fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
17
+ match self {
18
+ Color :: Green => write ! ( f, "green" ) ,
19
+ Color :: Blue => write ! ( f, "blue" ) ,
20
+ Color :: Orange => write ! ( f, "orange" ) ,
21
+ Color :: Pink => write ! ( f, "pink" ) ,
22
+ Color :: Purple => write ! ( f, "purple" ) ,
23
+ }
24
+ }
25
+ }
3
26
4
27
#[ derive( TemplateOnce , Default ) ]
5
28
#[ template( path = "lists/item/template.html" ) ]
6
29
pub struct Item {
7
30
value : String ,
31
+ color : Color ,
8
32
}
9
33
10
34
impl Item {
11
35
pub fn new ( ) -> Item {
12
36
Item {
13
37
value : String :: from ( "Your list item" ) ,
38
+ color : Color :: Green ,
14
39
}
15
40
}
16
41
17
42
pub fn value ( mut self , value : & str ) -> Item {
18
43
self . value = value. into ( ) ;
19
44
self
20
45
}
46
+
47
+ pub fn color ( mut self , color : Color ) -> Item {
48
+ self . color = color;
49
+ self
50
+ }
21
51
}
22
52
23
53
component ! ( Item ) ;
Original file line number Diff line number Diff line change 1
1
< div class ="list-group-item d-flex align-items-center gap-2 ">
2
- < img loading ="lazy " src ="/dashboard/static/images/icons/checkmark.svg " width ="15 " height ="11 " alt ="Checkmark ">
2
+ < span class ="material-symbols-outlined text-gradient-<%- color.to_string() %> align-self-start ">
3
+ check
4
+ </ span >
3
5
< %- value %>
4
6
</ div >
Original file line number Diff line number Diff line change 13
13
14
14
< div class ="collapse navbar-collapse " id ="navbarSupportedContent ">
15
15
< ul class ="navbar-nav flex-grow-1 gap-4 me-auto mb-4 mb-lg-0 ">
16
+ < % if !standalone_dashboard { %>
17
+ < li class ="nav-item d-flex align-items-center ">
18
+ < a class ="nav-link p-0 " href ="/plans "> Pricing</ a >
19
+ </ li >
20
+ < % } %>
16
21
< li class ="nav-item d-flex align-items-center ">
17
22
< a class ="nav-link p-0 " href ="/docs/guides/ "> Docs</ a >
18
23
</ li >
19
- < % if !standalone_dashboard { %>
20
- <!-- <li class="nav-item d-flex align-items-center">
21
- <a class="nav-link p-0" href="/plan_comparison">Pricing</a>
22
- </li> -->
23
- < % } %>
24
24
< li class ="nav-item d-flex align-items-center ">
25
25
< a class ="nav-link p-0 " href ="/blog/speeding-up-vector-recall-by-5x-with-hnsw "> Blog</ a >
26
26
</ li >
Original file line number Diff line number Diff line change @@ -74,15 +74,6 @@ article {
74
74
background-color : #{$bg-white } !important ;
75
75
}
76
76
77
- // Our flagship gradient.
78
- .party-time {
79
- background : $gradient-text ;
80
- -webkit-background-clip : text ;
81
- -webkit-text-fill-color : transparent ;
82
- background-clip : text ;
83
- text-fill-color : transparent ;
84
- }
85
-
86
77
// Remove padding from large screens.
87
78
@include media-breakpoint-up (lg) {
88
79
body {
@@ -116,14 +107,6 @@ article {
116
107
background : #{$purple } ;
117
108
}
118
109
119
- .syntax-highlight {
120
- background : $gradient-blue ;
121
- -webkit-background-clip : text ;
122
- -webkit-text-fill-color : transparent ;
123
- background-clip : text ;
124
- text-fill-color : transparent ;
125
- }
126
-
127
110
.noselect {
128
111
-webkit-touch-callout : none ; /* iOS Safari */
129
112
-webkit-user-select : none ; /* Safari */
Original file line number Diff line number Diff line change @@ -90,7 +90,7 @@ h6, .h6 {
90
90
background-clip : text ;
91
91
text-fill-color : transparent ;
92
92
}
93
- .text-gradient-blue {
93
+ .text-gradient-blue , .syntax-highlight {
94
94
@include text-gradient ($gradient-blue );
95
95
}
96
96
.text-gradient-green {
@@ -105,6 +105,9 @@ h6, .h6 {
105
105
.text-gradient-purple {
106
106
@include text-gradient ($gradient-purple );
107
107
}
108
+ .text-gradient-party , .party-time {
109
+ @include text-gradient ($gradient-text );
110
+ }
108
111
109
112
110
113
.marketing-body-large {
You can’t perform that action at this time.
0 commit comments