The horizontal scrolling feature in tables is not functioning properly on iOS Safari

Having trouble getting a horizontal scroll to work on my table in a React app, specifically on iOS Safari. It works fine on other platforms.

Here is a snippet from my JS file:

<div className={styles.parent}>
  <div className={styles.wrapper}>
    <table className={styles.table}>...</table>
  </div>
<div>

And here's the relevant CSS code:

.parent {
  width: 100%;
  overflow-x: hidden; 
}

.wrapper {
  position: relative;
}
.table {
  background: transparent;
  border-spacing: 12px 0;
  min-width: 1em;
  display: block;
  overflow-x: auto;
  max-width: none;
  -webkit-overflow-scrolling: touch !important;
}

Answer №1

I suggest giving this a try as it may be useful for you:

.wrapper {
  max-width: 100%;
  overflow-y: auto; 
}

Appreciate your consideration.

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

not getting any notifications from PHP

Despite receiving a status of '1' from this process file, my JavaScript code seems to be working fine. However, I am facing an issue with not receiving the email. <?php //Retrieve form data. //GET - user submitted data using AJAX //POST - in ...

The back button on the page does not reset the CSS styling

I have a button that activates navigation to a different page. When this button is clicked, it changes the current section/page's display settings to none and sets the new section/page's display to block. <div class="listLeft">&l ...

Is there a way to move a list item element to the right within a navigation tabs bar using Bootstrap 5?

I've been scouring the internet for tips on how to move my "User information" and "Logout" li elements to the right of my navbar using bootstrap, but I can't seem to find a solution. As a beginner with bootstrap, this task has proven to be quite ...

Tips for implementing Java code within a JSP <c:if> statement

How can I utilize the "ft" value in a c:if statement? <% Date dNow = new Date( ); SimpleDateFormat ft = new SimpleDateFormat ("yyyy.MM.dd hh:mm:ss a zzz"); out.print( "<h2 align=\"center\">" + ft.format(dNow) + "</h2> ...

React element featuring various interfaces

Currently, I am working on styling a React component in a way that allows for either horizontal or vertical styling without using flexbox. My question is, how can I pass styles down to the component in a way that applies individual styles to the child ele ...

Unable to delete component from an array (slice, Vue.js)

I'm currently working on implementing dynamic addition and removal of components in Vue.js. I've encountered an issue with the slice method, which is supposed to remove an element from an array by the provided index. To modify the array, I am us ...

Encountering Issues when Attempting to Generate a Fresh React Application through the Command Line

After running the command shown below, I encountered several error messages. npx create-react-app my-app The specific errors I encountered are as follows: npm ERR! Unexpected end of JSON input while parsing near '...8olCMjOZDx5OzCM3r6Cqh' ...

Attempted to invoke the function {promiseMethodWrapper} synchronously from another thread

This is my first attempt at integrating react-native with a native iOS app. In my react-native iOS project, I have created a Swift file that generates a bridging header. Inside this Swift file, I have implemented a test method as follows: import Foundatio ...

What is the best way to embed PHP code into a jQuery append using AJAX?

After searching for information on "How to insert PHP into jQuery?", I have not been able to find the solution that I need. I have a todo list in php and I am trying to implement ajax functionality into it. When the ajax call is successful, I want to appen ...

The button's background color remains the same even after clicking on it

In my exploration of Vue.js, I decided to create a simple project to grasp the concept of class binding. I wanted to add functionality to each button component, so that when a button is clicked, it would change its color or background color to something ot ...

Is it possible to update the variable value in one controller from another controller after an http.get request has been made

I have encountered an issue with updating a variable from one controller to another using a service. Despite my efforts, the variable is not being updated. The goal is to have the variable $scope.names in controller 'select' update in controller ...

The browser automatically adds a backslash escape character to a JavaScript object

When attempting to send an MQTT message to a topic from my angular app, the message needs to be in a specific syntax: { "Message": "hello" //the space after : is mandatory } However, upon sending the message in the correct format, the browser aut ...

Click on any checkbox to select all checkboxes at once

I have created a table with each column containing a checkbox. My goal is to select all checkboxes in the table when I click on the checkbox in the top row (th). Can someone guide me on how to achieve this? Below is my code: <table style="width:100%"& ...

Solving data within an Angular Controller

Recently delving into Angular development, I've found myself caught in a loop trying to solve this particular issue. To give some context, I'm utilizing the MEAN stack through mean.io which includes Angular UI Router functionalities. In my data ...

The presence of a constructor in a component disrupts the connection between React and Redux in

I am facing an issue with the connect function from 'react-redux' in my Typescript class example. The error occurs at the last line and I'm struggling to understand why it's happening. The constructor is necessary for other parts of the ...

Tips for creating multiple files using nodejs and express

I am currently working on developing a personalized code editor that consists of 3 textareas: html, css, and javascript. The objective is to save the data from each textarea into individual files. With the help of express and nodejs, I have successfully m ...

Creating consistent styles with createStyles()

I created a custom component with unique styles using createStyles({}). It is mostly working as intended, but I also implemented createGenerateClassName({}) to ensure consistent class names. However, the two methods are not fully compatible. The standard M ...

Using React, utilize the state value in a parent component to determine when to call the child component

I need help passing data from a parent component to a child component grid. The parent component has a state for the data, which is updated after fetching data from an API. Currently, the child component is only called if the state length is greater than 0 ...

Dealing with Unwanted Keys When Parsing JSON Objects

Struggling with parsing a list of Objects, for example: After running the code JSON.parse("[{},{},{},{},{}]"); The result is as follows: 0: Object 1: Object 2: Object 3: Object 4: Object 5: Object Expecting an array of 5 objects like this: [Object,Ob ...

The 'prop' property is not found in the 'A | B' type

When retrieving data from a URL, if a specific condition is met, the information will be loaded into either type B or its superclass A. However, an issue arises when the data is loaded into B and TypeScript fails to recognize its properties. The code sni ...