clog/tutorial/28-tutorial/hello-builder/hello.lisp
2022-01-27 22:31:30 -05:00

12 lines
963 B
Common Lisp

;; do not edit - file generated by clog-builder
(in-package "HELLO-BUILDER")
(defclass hello-page (clog:clog-div)
((my-button :reader my-button)(hello-span :reader hello-span)))
(defun create-hello-page (clog-obj)
(let ((panel (change-class (clog:create-div clog-obj :content "<button id=\"CLOGB38523257302\" class=\"\" style=\"box-sizing: content-box; position: absolute; left: 144px; top: 49.9911px;\">Click Me!</button><span id=\"CLOGB38523250771\" style=\"box-sizing: content-box; position: absolute; left: 141px; top: 14px; height: 22px; color: rgb(0, 0, 255);\">Hello World!</span>") 'hello-page)))
(setf (slot-value panel 'my-button) (attach-as-child clog-obj "CLOGB38523257302" :clog-type 'CLOG:CLOG-BUTTON :new-id t))
(setf (slot-value panel 'hello-span) (attach-as-child clog-obj "CLOGB38523250771" :clog-type 'CLOG:CLOG-SPAN :new-id t))
(set-on-click (my-button panel) (lambda (target) (declare (ignorable target)) (my-click panel)))
panel))