]> git.eshelyaron.com Git - emacs.git/commitdiff
Complete property values in multi-line CSS declarations
authorSimen Heggestøyl <simenheg@gmail.com>
Mon, 26 Oct 2020 09:01:44 +0000 (10:01 +0100)
committerSimen Heggestøyl <simenheg@runbox.com>
Tue, 27 Oct 2020 14:19:58 +0000 (15:19 +0100)
* lisp/textmodes/css-mode.el (css--complete-property-value): Complete
property values even when preceded by a newline (bug#44214).

lisp/textmodes/css-mode.el

index 0d1eeed5611ff6425315c772bcd5636ed30e2647..748a561bab5ec9c6ede1a28369ad732d7711bc38 100644 (file)
@@ -1357,7 +1357,9 @@ the string PROPERTY."
 (defun css--complete-property-value ()
   "Complete property value at point."
   (let ((property (and (looking-back "\\([[:alnum:]-]+\\):[^/][^;]*"
-                                     (line-beginning-position) t)
+                                     (or (ppss-innermost-start (syntax-ppss))
+                                         (point-min))
+                                     t)
                        (member (match-string-no-properties 1)
                                css-property-ids))))
     (when property