diff --git a/source/clog-element.lisp b/source/clog-element.lisp index 08256f7..96189c0 100644 --- a/source/clog-element.lisp +++ b/source/clog-element.lisp @@ -235,6 +235,29 @@ after attachment is changed to one unique to this session.")) (jquery-execute obj (format nil "append(~A)" (script-id next-obj))) next-obj) +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;; place-text-inside-top-of ;; +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + +(defgeneric place-text-inside-top-of (clog-obj text) + (:documentation "Places text inside top of CLOG-OBJ in DOM")) + +(defmethod place-text-inside-top-of ((obj clog-obj) text) + (jquery-execute obj (format nil "prepend(document.createTextNode('~A'))" text)) + text) + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;; place-text-inside-bottom-of ;; +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + +(defgeneric place-text-inside-bottom-of (clog-obj text) + (:documentation "Places text inside bottom of CLOG-OBJ in DOM")) + +(defmethod place-text-inside-bottom-of ((obj clog-obj) text) + (jquery-execute obj (format nil "append(document.createTextNode('~A'))" text)) + text) + + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; Properties - clog-element ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; diff --git a/source/clog.lisp b/source/clog.lisp index 6a61372..9c02924 100644 --- a/source/clog.lisp +++ b/source/clog.lisp @@ -197,10 +197,12 @@ embedded in a native template application.)" (attach-as-child generic-function) "CLOG-Element - DOM Placement" - (place-after generic-function) - (place-before generic-function) - (place-inside-top-of generic-function) - (place-inside-bottom-of generic-function) + (place-after generic-function) + (place-before generic-function) + (place-inside-top-of generic-function) + (place-inside-bottom-of generic-function) + (place-text-inside-top-of generic-function) + (place-text-inside-bottom-of generic-function) "CLOG-Element - General Properties" (style generic-function)