Lose the faff, bring back the fun with toepoke.co.uk
Fork me on GitHub

Fluqi

Ease jQuery UI development with a Fluqi library

Simply play with the properties on the Widget Properties tab, click the Update button to regenerate the C#, HTML and JavaScript. Once the page has loaded have a look at the Widget Methods tab to see how you can interact with the widget.

jQuery Events Log

Tick the Show & Render Events checkbox to start showing the events (and click Update).

My Panel 1

Proin elit arcu, rutrum commodo, vehicula tempus, commodo a, risus. Curabitur nec arcu. Donec sollicitudin mi sit amet mauris. Nam elementum quam ullamcorper ante. Etiam aliquet massa et lorem. Mauris dapibus lacus auctor risus. Aenean tempor ullamcorper leo. Vivamus sed magna quis ligula eleifend adipiscing. Duis orci. Aliquam sodales tortor vitae ipsum. Aliquam nulla. Duis aliquam molestie erat. Ut et mauris vel pede varius sollicitudin. Sed ut dolor nec orci tincidunt interdum. Phasellus ipsum. Nunc tristique tempus lectus.

My Panel 2

Morbi tincidunt, dui sit amet facilisis feugiat, odio metus gravida ante, ut pharetra massa metus id nunc. Duis scelerisque molestie turpis. Sed fringilla, massa eget luctus malesuada, metus eros molestie lectus, ut tempus eros massa ut dolor. Aenean aliquet fringilla sem. Suspendisse sed ligula in ligula suscipit aliquam. Praesent in eros vestibulum mi adipiscing adipiscing. Morbi facilisis. Curabitur ornare consequat nunc. Aenean vel metus. Ut posuere viverra nulla. Aliquam erat volutpat. Pellentesque convallis. Maecenas feugiat, tellus pellentesque pretium posuere, felis lorem euismod felis, eu ornare leo nisi vel felis. Mauris consectetur tortor et purus.

My Panel 3

Mauris eleifend est et turpis. Duis id erat. Suspendisse potenti. Aliquam vulputate, pede vel vehicula accumsan, mi neque rutrum erat, eu congue orci lorem eget lorem. Vestibulum non ante. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Fusce sodales. Quisque eu urna vel enim commodo pellentesque. Praesent eu risus hendrerit ligula tempus pretium. Curabitur lorem enim, pretium nec, feugiat nec, luctus a, lacus.

Duis cursus. Maecenas ligula eros, blandit nec, pharetra at, semper at, magna. Nullam ac lacus. Nulla facilisi. Praesent viverra justo vitae neque. Praesent blandit adipiscing velit. Suspendisse potenti. Donec mattis, pede vel pharetra blandit, magna ligula faucibus eros, id euismod lacus dolor eget odio. Nam scelerisque. Donec non libero sed nulla mattis commodo. Ut sagittis. Donec nisi lectus, feugiat porttitor, tempor ac, tempor vitae, pede. Aenean vehicula velit eu tellus interdum rutrum. Maecenas commodo. Pellentesque nec elit. Fusce in lacus. Vivamus a libero vitae lectus hendrerit hendrerit.


Test Harness Options

Here are the methods available for the jQuery UI control, have a click on the buttons and see how the behaviour of the control changes.

Below is the code required to use the options you have selected above.

									
<%
var ac = Html.CreateAccordion("ac")
	.Options
		.SetHeightStyle("auto")
	.Finish()
	.Events
		.SetCreateEvent("return createEvent(event, ui);")
		.SetactivateEvent("return activateEvent(event, ui);")
		.SetBeforeActivateEvent("return beforeActivateEvent(event, ui);")
	.Finish()
	.Panels
		.Add("My Panel 1", true)
		.Add("My Panel 2")
		.Add("My Panel 3")
	.Finish()
;
%>

<%using (ac.RenderContainer()) {%>
	<%using (ac.Panels.RenderNextPane()) {%>
		

Proin ...

<%}%> <%using (ac.Panels.RenderNextPane()) {%>

Morbi ...

<%}%> <%using (ac.Panels.RenderNextPane()) {%>

Mauris ...

<%}%> <%}%>

Which produces the following HTML mark-up.

									

My Panel 1

Proin ...

My Panel 2

Morbi ...

My Panel 3

Mauris ...

Which initialises the control with the following [generated] JavaScript.

									




								

Notice how Fluqi generates the minimum JavaScript necessary to configure the widget, minimising the download to the browser.

You can also change the theme used by jQuery UI using the switcher. Also note you can see the events for the control as they happen in the jQuery Events log (this also adds the event code to the JS Code tab ... uncheck the Show & Render Events option to stop this).