// Code generated by applyconfiguration-gen. DO NOT EDIT.

package v1

import (
	operatorv1 "github.com/openshift/api/operator/v1"
)

// LogoApplyConfiguration represents a declarative configuration of the Logo type for use
// with apply.
//
// Logo defines a configuration based on theme modes for the console UI logo.
type LogoApplyConfiguration struct {
	// type specifies the type of the logo for the console UI. It determines whether the logo is for the masthead or favicon.
	// type is a required field that allows values of Masthead and Favicon.
	// When set to "Masthead", the logo will be used in the masthead and about modal of the console UI.
	// When set to "Favicon", the logo will be used as the favicon of the console UI.
	Type *operatorv1.LogoType `json:"type,omitempty"`
	// themes specifies the themes for the console UI logo.
	// themes is a required field that allows a list of themes. Each item in the themes list must have a unique mode and a source field.
	// Each mode determines whether the logo is for the dark or light mode of the console UI.
	// If a theme is not specified, the default OpenShift logo will be displayed for that theme.
	// There must be at least one entry and no more than 2 entries.
	Themes []ThemeApplyConfiguration `json:"themes,omitempty"`
}

// LogoApplyConfiguration constructs a declarative configuration of the Logo type for use with
// apply.
func Logo() *LogoApplyConfiguration {
	return &LogoApplyConfiguration{}
}

// WithType sets the Type field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the Type field is set to the value of the last call.
func (b *LogoApplyConfiguration) WithType(value operatorv1.LogoType) *LogoApplyConfiguration {
	b.Type = &value
	return b
}

// WithThemes adds the given value to the Themes field in the declarative configuration
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
// If called multiple times, values provided by each call will be appended to the Themes field.
func (b *LogoApplyConfiguration) WithThemes(values ...*ThemeApplyConfiguration) *LogoApplyConfiguration {
	for i := range values {
		if values[i] == nil {
			panic("nil value passed to WithThemes")
		}
		b.Themes = append(b.Themes, *values[i])
	}
	return b
}
