Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add flight icon to document types configuration #479

Merged
merged 1 commit into from
Dec 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions configs/config.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ document_types {
document_type "RFC" {
long_name = "Request for Comments"
description = "Create a Request for Comments document to present a proposal to colleagues for their review and feedback."
flight_icon = "discussion-circle"
template = "1Oz_7FhaWxdFUDEzKCC5Cy58t57C4znmC_Qr80BORy1U"

more_info_link {
Expand Down Expand Up @@ -58,6 +59,7 @@ document_types {
document_type "PRD" {
long_name = "Product Requirements"
description = "Create a Product Requirements Document to summarize a problem statement and outline a phased approach to addressing the problem."
flight_icon = "target"
template = "1oS4q6IPDr3aMSTTk9UDdOnEcFwVWW9kT8ePCNqcg1P4"

more_info_link {
Expand All @@ -78,6 +80,7 @@ document_types {
// document_type "Memo" {
// long_name = "Memo"
// description = "Create a Memo document to share an idea or brief note with colleagues."
// flight_icon = "radio"
// template = "file-id-for-a-blank-doc"
// }
}
Expand Down
1 change: 1 addition & 0 deletions internal/cmd/commands/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -495,6 +495,7 @@ func registerDocumentTypes(cfg config.Config, db *gorm.DB) error {
Name: d.Name,
LongName: d.LongName,
Description: d.Description,
FlightIcon: d.FlightIcon,
Checks: checksJSON,
CustomFields: cfs,
}
Expand Down
4 changes: 4 additions & 0 deletions internal/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,10 @@ type DocumentType struct {
// colleagues for their review and feedback."
Description string `hcl:"description,optional" json:"description"`

// FlightIcon is the name of the Helios flight icon.
// From: https://helios.hashicorp.design/icons/library
FlightIcon string `hcl:"flight_icon,optional" json:"flightIcon"`

// Template is the Google file ID for the document template used for this
// document type.
Template string `hcl:"template"`
Expand Down
4 changes: 4 additions & 0 deletions pkg/models/document_type.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ type DocumentType struct {
// colleagues for their review and feedback."
Description string

// FlightIcon is the name of the Helios flight icon.
// From: https://helios.hashicorp.design/icons/library
FlightIcon string

// MoreInfoLinkText is the text for a "more info" link.
// Example: "When should I create an RFC?"
MoreInfoLinkText string
Expand Down