Nanocomposite-based stretchable optics