Documentation ¶
Overview ¶
Nging is a toolbox for webmasters Copyright (C) 2018-present Wenhui Shen <swh@admpub.com>
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License along with this program. If not, see <https://www.gnu.org/licenses/>.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( DefaultModal = Modal{ ExtButtons: []Button{}, } PathFixer = func(ctx echo.Context, conf string) string { return conf } ReadConfigFile = func(file string) ([]byte, error) { return os.ReadFile(file) } WriteConfigFile = func(file string, b []byte) error { err := com.MkdirAll(filepath.Dir(file), os.ModePerm) if err != nil { return err } return os.WriteFile(file, b, os.ModePerm) } )
Functions ¶
Types ¶
type Modal ¶
type Modal struct { Id string //元素id Custom bool //是否自定义整个内容区域 HeadTitle string //头部标题 Title string //内容标题 Content string //内容 HelpText string //帮助提示 Animate string //动画样式class名 Type string //类型:warning/primary/success/danger ContentType string //内容类型:form/blackform/"" ExtButtons []Button //附加按钮 [{Text:"🔃重载",Attributes:[{Attr:"class",Value:"btn btn-warning btn-reload"}]}] }