MCPcopy Create free account
hub / github.com/bajrangCoder/setu / render_api_key_auth

Method render_api_key_auth

src/components/auth_editor.rs:593–665  ·  view source on GitHub ↗
(&self, theme: &gpui_component::theme::ThemeColor)

Source from the content-addressed store, hash-verified

591 .border_1()
592 .border_color(theme.border)
593 .child(CompletionInput::new(
594 input,
595 Input::new(input).appearance(false).small(),
596 )),
597 )
598 })
599 }
600
601 fn render_api_key_auth(&self, theme: &gpui_component::theme::ThemeColor) -> impl IntoElement {
602 div()
603 .flex()
604 .flex_col()
605 .gap(px(16.0))
606 // Add to selector
607 .child(
608 div()
609 .flex()
610 .flex_col()
611 .gap(px(6.0))
612 .child(
613 div()
614 .text_color(theme.muted_foreground)
615 .text_size(px(11.0))
616 .font_weight(gpui::FontWeight::SEMIBOLD)
617 .child("Add to"),
618 )
619 .child(
620 Select::new(&self.api_key_location_select)
621 .small()
622 .menu_width(px(120.0)),
623 ),
624 )
625 // Key name
626 .child(
627 div()
628 .flex()
629 .flex_col()
630 .gap(px(6.0))
631 .child(
632 div()
633 .text_color(theme.muted_foreground)
634 .text_size(px(11.0))
635 .font_weight(gpui::FontWeight::SEMIBOLD)
636 .child("Key"),
637 )
638 .when_some(self.api_key_name_input.as_ref(), |el, input| {
639 el.child(
640 div()
641 .bg(theme.secondary)
642 .rounded(px(6.0))
643 .border_1()
644 .border_color(theme.border)
645 .child(CompletionInput::new(
646 input,
647 Input::new(input).appearance(false).small(),
648 )),
649 )
650 }),

Callers 1

renderMethod · 0.80

Calls 1

childMethod · 0.80

Tested by

no test coverage detected