Jump to content

Slider images appear truncated in IOS vs. PC


Chrisj

Recommended Posts

I installed a javascript slider and added my images, but my images apparently have a sizing issue, I can see more width of the image on my pc screen, but on an iphone the image seems almost cut in half. 

Any ideas how to remedy will be appreciated. Here's some relevant code:

html, body, .container {
	height: 100%;
}

.js .boxgallery,
.js .boxgallery div {
	position: absolute;
}

.js .boxgallery,
.bg-tile,
.bg-img {
	overflow: hidden;
}

.js .boxgallery,
.js .panel {
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
}

.panel {
	z-index: 0;
	-webkit-perspective: 1200px;
	perspective: 1200px;
}

.bg-tile {
	width: 50%;
	height: 50%;
}

.bg-tile:nth-child(2),
.bg-tile:nth-child(4) {
	left: 50%;
}

.bg-tile:nth-child(3),
.bg-tile:nth-child(4) {
	top: 50%;
}

.bg-img {
	width: 100%;
	height: 100%;
	background: #999;
}

.bg-img img {
	position: absolute;
	display: block;
	height: 200%;
}

@media screen and (min-aspect-ratio: 1280/850) {
	.bg-img img {
		width: 200%;
		height: auto;
	}
}

.bg-tile:nth-child(2) .bg-img img,
.bg-tile:nth-child(4) .bg-img img {
	left: -100%;
}

.bg-tile:nth-child(3) .bg-img img,
.bg-tile:nth-child(4) .bg-img img {
	top: -100%;
}

Any help will be appreciated.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.