(list (point) pos
(if (eq (char-before (- (point) 1)) ?\:)
css-pseudo-element-ids
- css-pseudo-class-ids))))))
+ css-pseudo-class-ids)
+ :company-kind (lambda (_) 'function))))))
(defun css--complete-at-rule ()
"Complete at-rule (statement beginning with `@') at point."
(let ((pos (point)))
(skip-chars-backward "-[:alnum:]")
(when (eq (char-before) ?\@)
- (list (point) pos css--at-ids)))))
+ (list (point) pos css--at-ids
+ :company-kind (lambda (_) 'keyword))))))
(defvar css--property-value-cache
(make-hash-table :test 'equal :size (length css-property-alist))
(skip-chars-backward "[:graph:]")
(list (point) end
(append '("inherit" "initial" "unset")
- (css--property-values (car property)))))))))
+ (css--property-values (car property)))
+ :company-kind (lambda (_) 'value)))))))
(defvar css--html-tags (mapcar #'car html-tag-alist)
"List of HTML tags.
(list prop-beg prop-end)
(list sel-beg sel-end))
,(completion-table-merge prop-table sel-table)
+ :company-kind
+ ,(lambda (s) (if (test-completion s prop-table) 'property 'keyword))
:exit-function
,(lambda (string status)
(and (eq status 'finished)