Using Lagrange elements with higher order shape functions in FEniCSx

Hi, everyone.
I am trying to investigate the behaviour of increasing shape function order in FEniCSx. I want to implement Lagrange elements with shape functions having an order of polynomials up to 8, for quadrilaterals and hexahedrons. In the documentation of LagrangeVariant, only order 3 for quadrilaterals and order 2 for hexahedrons have been mentioned.

V = fem.functionspace(domain, ("Lagrange", deg_u, (domain.geometry.dim, )))

I was playing around with increasing deg_u, and the code would compile even for deg_u > 3 for 2D quadrilaterals. Will simply increasing the value of deg_u be sufficient to generate higher order shape functions, or do I have to implement a custom element as shown as in this demo?
Thanks!

By increasing deg_u you get an arbitrary order degree finite element.
DefElement only shows the lowest order degrees as it uses symbolic software to define the basis functions for the webpage and visualization, and thus only do those that are sufficiently fast. DOLFINx supports arbitrary order elements of the following families (if arbitrary order makes sense for the given family):