Cantor Function, Cruel
JavaScript (ES7),  141 ... 128  125 bytes
Saved 2 bytes thanks to @Ada
Expects the fraction \$p/q\$ as (p)(q). Returns \$P/Q\$ as [P,Q].

p=&gt;q=&gt;(k='0b'+(n=0,g=p=&gt;(r=n-g[p])?'':p/q&amp;1||[p/q&gt;&gt;1]+g(p%q*3,g[p]=n++))(p),r?[((k&gt;&gt;r)*(m=2**r-1)+(k&amp;m))*2,m&lt;&lt;n-r]:[+k,1&lt;&lt;n])

Try it online!
How?
Ternary and binary expansions
k =                    // build a binary string
  '0b' + (             // append the binary prefix
    n = 0,             // n is a bit counter
    g = p =&gt;           // g is a recursive function taking the numerator p
      (r = n - g[p]) ? //   if p was already encountered, we have a repeating
                       //   pattern, whose length is stored in r; in that case:
        ''             //     stop the recursion
      :                //   else:
        p / q &amp; 1 ||   //     if p/q = 1, append a '1' and stop the recursion
        [p / q &gt;&gt; 1] + //     otherwise, append '1' if p/q = 2 or '0' if p/q = 0
        g(             //     append the result of a recursive call to g:
          3 * (p % q), //       update p to 3 * (p modulo q)
          g[p] = n++   //       store the position of p in g and increment n
        )              //     end of recursive call
  )(p)                 // initial call with the numerator provided in the input

Turning the binary expansion into a decimal fraction
If \$r\$ is NaN after the first step, it means that the binary expansion has no repeating pattern. In that case, the numerator is \$k\$ and the denominator is \$2^n\$.
If \$r\$ is defined, we compute the following bitmask:
m = 2 ** r - 1

The numerator is:
((k &gt;&gt; r) * m + (k &amp; m)) * 2

and the denominator is:
m &lt;&lt; n - r