github.com/google/safehtml/template.context.attr (field)
37 uses
github.com/google/safehtml/template (current package)
context.go#L22: attr attr
context.go#L46: c.attr.eq(d.attr) &&
escape.go#L314: a.attr.names = joinNames(a.attr.name, b.attr.name, a.attr.names, b.attr.names)
escape.go#L315: if a.attr.value != b.attr.value {
escape.go#L316: a.attr.ambiguousValue = true
escape.go#L333: c.attr.name = b.attr.name
escape.go#L467: if c.attr.name != "" {
escape.go#L468: s += "_" + c.attr.String()
escape.go#L591: if e.ns.cspCompatible && strings.HasPrefix(c.attr.name, "on") {
escape.go#L594: err: errorf(ErrCSPCompatibility, n, 0, "inline event handler %q is disallowed for CSP compatibility", c.attr.name),
escape.go#L690: c.attr.value += string(s)
escape.go#L711: if c.state == stateAttr && c.element.name == "script" && c.attr.name == "type" {
escape.go#L715: if c.state == stateAttr && c.element.name == "link" && c.attr.name == "rel" {
sanitize.go#L26: if c.attr.name != "" || len(c.attr.names) > 0 {
sanitize.go#L60: if len(c.attr.names) == 0 {
sanitize.go#L61: attrs = []string{c.attr.name}
sanitize.go#L63: attrs = c.attr.names
sanitize.go#L87: if sc0.isEnum() && c.attr.value != "" {
sanitize.go#L88: return nil, fmt.Errorf("partial substitutions are disallowed in the %q attribute value context of a %q element", c.attr.name, c.element.name)
sanitize.go#L90: if sc0 == sanitizationContextStyle && c.attr.value != "" {
sanitize.go#L91: if err := validateDoesNotEndsWithCharRefPrefix(c.attr.value); err != nil {
sanitize.go#L92: return nil, fmt.Errorf("action cannot be interpolated into the %q attribute value of this %q element: %s", c.attr.name, c.element.name, err)
sanitize.go#L105: urlAttrValPrefix := c.attr.value
sanitize.go#L112: if c.attr.ambiguousValue {
sanitize.go#L113: return nil, fmt.Errorf("actions must not occur after an ambiguous URL prefix in the %q attribute value context of a %q element", c.attr.name, c.element.name)
sanitize.go#L117: return nil, fmt.Errorf("cannot validate attribute value prefix %q in the %q sanitization context", c.attr.value, sc0)
sanitize.go#L119: if err := validator(c.attr.value); err != nil {
sanitize.go#L120: return nil, fmt.Errorf("action cannot be interpolated into the %q URL attribute value of this %q element: %s", c.attr.name, c.element.name, err)
transition.go#L138: attr: attr{name: strings.ToLower(string(s[i:j]))},
 |
The pages are generated with Golds v0.3.2-preview. (GOOS=darwin GOARCH=amd64)
Golds is a Go 101 project developed by Tapir Liu.
PR and bug reports are welcome and can be submitted to the issue list.
Please follow @Go100and1 (reachable from the left QR code) to get the latest news of Golds. |