mirror of
https://github.com/thomiceli/opengist.git
synced 2025-07-08 09:01:20 +02:00
feat: make edit visibility a toggle (#277)
* feat: make edit visibility a toggle Signed-off-by: jolheiser <john.olheiser@gmail.com> * Tweak SVG dropdown icon size & color --------- Signed-off-by: jolheiser <john.olheiser@gmail.com> Co-authored-by: Thomas Miceli <tho.miceli@gmail.com>
This commit is contained in:
@ -538,13 +538,17 @@ func (gist *Gist) GetLanguagesFromFiles() ([]string, error) {
|
||||
// -- DTO -- //
|
||||
|
||||
type GistDTO struct {
|
||||
Title string `validate:"max=250" form:"title"`
|
||||
Description string `validate:"max=1000" form:"description"`
|
||||
URL string `validate:"max=32,alphanumdashorempty" form:"url"`
|
||||
Private Visibility `validate:"number,min=0,max=2" form:"private"`
|
||||
Files []FileDTO `validate:"min=1,dive"`
|
||||
Name []string `form:"name"`
|
||||
Content []string `form:"content"`
|
||||
Title string `validate:"max=250" form:"title"`
|
||||
Description string `validate:"max=1000" form:"description"`
|
||||
URL string `validate:"max=32,alphanumdashorempty" form:"url"`
|
||||
Files []FileDTO `validate:"min=1,dive"`
|
||||
Name []string `form:"name"`
|
||||
Content []string `form:"content"`
|
||||
VisibilityDTO
|
||||
}
|
||||
|
||||
type VisibilityDTO struct {
|
||||
Private Visibility `validate:"number,min=0,max=2" form:"private"`
|
||||
}
|
||||
|
||||
type FileDTO struct {
|
||||
|
Reference in New Issue
Block a user