Skip to content

Commit

Permalink
Merge pull request #43 from Lng88/master
Browse files Browse the repository at this point in the history
Add settings to set editor type and width of pages created
  • Loading branch information
c-seeger authored Apr 13, 2022
2 parents ac9afce + 9268c52 commit bc1fe35
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 3 deletions.
29 changes: 29 additions & 0 deletions content.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,35 @@ type Content struct {
Space Space `json:"space"`
History *History `json:"history,omitempty"`
Links *Links `json:"_links,omitempty"`
Metadata *Metadata `json:"metadata"`
}

// Metadata specifies metadata properties
type Metadata struct {
Properties *Properties `json:"properties"`
}

// Properties defines properties of the editor
type Properties struct {
Editor *Editor `json:"editor"`
ContentAppearanceDraft *ContentAppearanceDraft `json:"content-appearance-draft"`
ContentAppearancePublished *ContentAppearancePublished `json:"content-appearance-published"`
}

// Editor contains editor information
type Editor struct {
Key string `json:"key"`
Value string `json:"value"`
}

// ContentAppearanceDraft sets the appearance of the content in draft form
type ContentAppearanceDraft struct {
Value string `json:"value"`
}

// ContentAppearancePublished sets the appearance of the content in published form
type ContentAppearancePublished struct {
Value string `json:"value"`
}

// Links contains link information
Expand Down
6 changes: 3 additions & 3 deletions examples/content/content.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"fmt"
"log"

"github.com/virtomize/confluence-go-api"
goconfluence "github.com/virtomize/confluence-go-api"
)

func main() {
Expand Down Expand Up @@ -50,7 +50,7 @@ func main() {
Representation: "storage",
},
},
Version: goconfluence.Version{
Version: &goconfluence.Version{
Number: 1,
},
Space: goconfluence.Space{
Expand Down Expand Up @@ -81,7 +81,7 @@ func main() {
Representation: "storage",
},
},
Version: goconfluence.Version{
Version: &goconfluence.Version{
Number: 2,
},
Space: goconfluence.Space{
Expand Down

0 comments on commit bc1fe35

Please sign in to comment.